To whom ever came up with this and or maintains it, a BIG thumbs up. I'm impressed. Ya just can't make it any easier then this. As a newbie, this is a prefect intro to active/dynamic debugging. As a lazy sap. this is perfect for extending the time I can avoid learning how to properly debug and profile my code. I'll have to do that some day, but not right now.
For me all it took was to add my wonky files for monitoring, a single require, hit ctrl+shift+f8, type in a few 'for' loops, and I was able to see my screw ups within ten minutes. The previous day I looked over and mucked around with my code for over 3 hours and accomplished nothing. I had no idea why my simulation was acting so strange. This even included some of my normally printed data and graphics randomly disappearing without even a peep from lua/love2d. I can't verbally describe the problems, but it all revolved around something like this:
t={}
t[1] = true t[2] = 3 t[3] = 57 t[4] = "magnum"
t[1] = nil <--Oops
for k, v in ipairs(t) do
print(t[k])
end
A salute to LoveDebug!
LoveDebug - A whole new way of debugging your game
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: LoveDebug - A whole new way of debugging your game
Since this is a community project then you are thanking all of LÖVE's users that have worked on this , they are all listed on the first post.
I'm glad you found this tool useful and if you have any new ideas for LoveDebug then feel free to make a pull request on github.
I'm glad you found this tool useful and if you have any new ideas for LoveDebug then feel free to make a pull request on github.
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: LoveDebug - A whole new way of debugging your game
I just want to update you guys on lovedebug.
admin36 added a way to not halt you code while the console is open and I added a HUD that shows all the errors in real time.
Also, all the bugs with the window not showing up due to graphical transformations have been fixed, now you can transform your game's graphics without effecting the console.
Check out the first page to download the latest lovedebug 1.4.0, thanks for reading.
admin36 added a way to not halt you code while the console is open and I added a HUD that shows all the errors in real time.
Also, all the bugs with the window not showing up due to graphical transformations have been fixed, now you can transform your game's graphics without effecting the console.
Check out the first page to download the latest lovedebug 1.4.0, thanks for reading.
Re: LoveDebug - A whole new way of debugging your game
Curious...
Unofficial 1.4.0 is quite a spred from official 1.1.5. So why is this always tagged as ""unofifical"" when clearly the ""official" code from 1.1.5 isn't likely to work with a modern version of L2d? I'd imagine that when L2d hits the 1.0 release things are going to get worse. If the original author isn't around to update the code and you can't contact him, maybe its time for the current code base to become "Official"... Just say'n!
Unofficial 1.4.0 is quite a spred from official 1.1.5. So why is this always tagged as ""unofifical"" when clearly the ""official" code from 1.1.5 isn't likely to work with a modern version of L2d? I'd imagine that when L2d hits the 1.0 release things are going to get worse. If the original author isn't around to update the code and you can't contact him, maybe its time for the current code base to become "Official"... Just say'n!
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: LoveDebug - A whole new way of debugging your game
Let's just leave it as is, I'll respect the original developer at least until LÖVE 1.0 hits.Grubby wrote:Curious...
Unofficial 1.4.0 is quite a spred from official 1.1.5. So why is this always tagged as ""unofifical"" when clearly the ""official" code from 1.1.5 isn't likely to work with a modern version of L2d? I'd imagine that when L2d hits the 1.0 release things are going to get worse. If the original author isn't around to update the code and you can't contact him, maybe its time for the current code base to become "Official"... Just say'n!
Re: LoveDebug - A whole new way of debugging your game
Is there a way of changing they hotkey for the debug console? I LOVE this plugin but would like it to be activated by tab.
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: LoveDebug - A whole new way of debugging your game
Sorry for replying so late.
Yeah, there's a way to change the hotkey but you'll need to create a global variable called "_lovedebugpresskey" and set it to "tab", this was added to version 1.2 by Qcode, but I'll change that in the next update so the key is set to a new variable in _DebugSettings instead of being tied to a global variable, unless you code that first, if so then check line 511 of lovedebug's code, that's lovedebug checks for the hotkey.
Yeah, there's a way to change the hotkey but you'll need to create a global variable called "_lovedebugpresskey" and set it to "tab", this was added to version 1.2 by Qcode, but I'll change that in the next update so the key is set to a new variable in _DebugSettings instead of being tied to a global variable, unless you code that first, if so then check line 511 of lovedebug's code, that's lovedebug checks for the hotkey.
Re: LoveDebug - A whole new way of debugging your game
Awesome! Thanks!
-
- Prole
- Posts: 34
- Joined: Sat Nov 28, 2015 5:54 am
Re: LoveDebug - A whole new way of debugging your game
This is a really great tool and I deleted some of my own debug tools after I found this gem!
One question about compatibility with other "middlewares". I put in strict.lua (http://metalua.luaforge.net/src/lib/strict.lua.html) into my game to check for global variables, but it conflicts with Lovedebug. Is this unavoidable because they both modify the same things?
One question about compatibility with other "middlewares". I put in strict.lua (http://metalua.luaforge.net/src/lib/strict.lua.html) into my game to check for global variables, but it conflicts with Lovedebug. Is this unavoidable because they both modify the same things?
Re: LoveDebug - A whole new way of debugging your game
So, i tried to use this nice script in my game. However...
For some odd reason, luafft now returns me an error, bragging about some debugging function not existing, when in fact it does.
With that error, the game splashcreen just stalls. I can hover at the button, but clicking it does nothing.
Actually, looking at the source code of both lovedebug and luafft i found the problem...
You guys use a variable named "msg" whilst luafft uses it as a "function"
What should i do? I really didn't plan on messing around with the source code of none of the external libs i used. I don't even know if i'm allowed to do so.
For some odd reason, luafft now returns me an error, bragging about some debugging function not existing, when in fact it does.
With that error, the game splashcreen just stalls. I can hover at the button, but clicking it does nothing.
Actually, looking at the source code of both lovedebug and luafft i found the problem...
You guys use a variable named "msg" whilst luafft uses it as a "function"
What should i do? I really didn't plan on messing around with the source code of none of the external libs i used. I don't even know if i'm allowed to do so.
https://github.com/Sulunia
Who is online
Users browsing this forum: No registered users and 10 guests