Page 1 of 1

Zerobrane Studio Löve2d Debug Mode Crash

Posted: Mon Jun 27, 2016 11:07 pm
by nexusdawn
Been using Sublime text for my love2d experiments. Just discovered Zerobrane Studio, it's syntax highlighting/suggestions, and debugging mode which all seem very nice and practical.

Running on Windows 8. No problems running any Love2d Lua scripts in Zerobranes 'run mode' (F6), but when trying to run in 'debug' mode. Love.exe just crashes/it remains open, with a white background not doing anything.

I've followed Zerobranes instructions on how to active the debug code in Love2d's script. But this information might be outdated as it is from 2012?

Perhaps I should also mention, I've tried this on the love2d 0.10.0 (Which Zerobrane is supposed to be compatible with as of version 1.3) 0.10.1 both 32 and 64 bit versions, and no go.

This is the simplest code sample I could come up with to help illustrate the problem is:

Code: Select all

function love.load(arg)
  if arg [#arg] == "-debug" then require("mobdebug").start() end
end

function love.draw()
  love.graphics.print("Hello World!", 400, 300)
end
Just starting to code and feel myself in programming after a 10-15 year break, so debugging would help a lot ;) Any advise would be much appreciated.

Thank you most kindly

Re: Zerobrane Studio Löve2d Debug Mode Crash

Posted: Mon Jun 27, 2016 11:52 pm
by nexusdawn
My bad, it seems for whatever reason (no I didn't insert a code line stop) The debugger code in Zerobrane Studio in Löve2d needs a 'Continue' debugging by pressing F5 (or by using the tool bar controls) after running the debug code:

Code: Select all

function love.load(arg)
  if arg [#arg] == "-debug" then require("mobdebug").start() end
end
Watch variables seem to update. Haven't tried stack or 'live coding updates'. But seems to work.

Hope this might be useful to anyone that may come across this issue.

Just in case, https://studio.zerobrane.com

Re: Zerobrane Studio Löve2d Debug Mode Crash

Posted: Tue Jun 28, 2016 9:41 am
by SiENcE
As good as Zerobrane is, more stable and advanced in debugging is VS2015+BabeLua. You should try it :).

Re: Zerobrane Studio Löve2d Debug Mode Crash

Posted: Tue Jun 28, 2016 7:08 pm
by paulclinger
> it seems for whatever reason (no I didn't insert a code line stop) The debugger code in Zerobrane Studio in Löve2d needs a 'Continue' debugging by pressing F5 (or by using the tool bar controls) after running the debug code:

@nexusdawn, yes, that's the default configuration for the Löve interpreter. You can make it run without stopping by adding `debugger.runonstart=true` to the config file (see: https://studio.zerobrane.com/doc-genera ... s#debugger). I should probably make it a default for Löve as this is not the first time it's being discussed. Paul.

Re: Zerobrane Studio Löve2d Debug Mode Crash

Posted: Wed Jun 29, 2016 1:03 pm
by fsc1
I registered / came to post about the "debugger.runonstart=true" option. But Paul, I'd like to say thanks for making Love2d come back to focus with that option enabled from version 1.20 to 1.30 (in 1.20 even with that option enabled Love2d at least for me stayed unfocused / behind ZBS). Great piece of software you have created Paul. New programmers can get started effortlessly with your IDE and Love2d, literally just by downloading both pieces of software and making sure that Love2d's in the system path (works also on Ubuntu the same way, no big complications).

Re: Zerobrane Studio Löve2d Debug Mode Crash

Posted: Wed Jun 29, 2016 11:37 pm
by paulclinger
@fsc1, thank you for the supportive feedback!

@nexusdawn, I've made the change to the Löve integration, so it will get included in the next release. If you want to give it a try, you can get the master branch from the repository, which also includes Löve API updated for v0.10.1.

Re: Zerobrane Studio Löve2d Debug Mode Crash

Posted: Thu Jun 30, 2016 10:56 am
by mr_happy
fsc1 wrote: Great piece of software you have created Paul.
I'd like to second that. Zerobrane is the most pleasant IDE I've ever used (and I've used a lot).