Page 1 of 1

Debug with Lua, LOVE, VS Code

Posted: Tue Sep 08, 2020 4:08 pm
by Nekyia
Hello! :awesome:

I would like to know how you approach debbuging with LOVE ?
I am using VS Code with the plugin 'tomblind.local-lua-debugger-vscode'. I started briefly with ZeroBrane Studio and the debugger worked very well, but was much more happy with vs code.
I would like to uninstall zbs, but still use it occasionaly for the Local Console. My problem with vs code is that often the debugger doesn't seem to work. For example I would set a breakpoint and the debugging will ignore it. Or it refuses to display the variable names.
I end up using a lot of print() and feel like I am wasting a lot of time on debug.

Also how do you debug graphically? Do you add lines in the middle of the code? Write functions, that you may removed later?

In many game you can open a console and show stuff and control parameters with cvars. I am aware of the LoveDebug library, but my skills are limited and I would rather do some games before coding a console system tailor-made.

Sometimes I run the debuger and find the problem immediatly, but mostly it is just print()
I feel inefficient and it is very frustrating.

I am curious about how more experienced and smarter people do it?

Re: Debug with Lua, LOVE, VS Code

Posted: Mon Sep 28, 2020 10:22 am
by D0NM
Just putting this old topic of yours here ... 0&p=234856

I remember running Love2D with VSC...
but the break point used to work once. I wasn't able to continue debugging. So I dropped the idea of debugging Love2D with VSC.

Re: Debug with Lua, LOVE, VS Code

Posted: Tue Sep 29, 2020 2:13 am
by sphyrth
I don't have a Rubber Duck with me, so I use that Inefficient Style you mentioned.