I'll demonstrate (give me a few hours )Ranguna259 wrote:isDown and a timer ? Would that work with the current Debug code ?
Debug - A whole new way of debugging your game
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Debug - A whole new way of debugging your game
Help us help you: attach a .love.
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: Debug - A whole new way of debugging your game
Hahaha sure, reading the whole sucks and takes quite a while xP I'm still doing it myself to implement live coding (no breakthroughs )
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Debug - A whole new way of debugging your game
That was easier than expected. I fixed some other things. (EDIT: I want to do some other things as well, expect a 1.2.8 soon! (This is addictive...))
Changelog
Version 1.2.7 (Not Official) by Robin
Changelog
Version 1.2.7 (Not Official) by Robin
- Brings back keyRepeat, in a way that doesn't interfere with the game.
- Fixes printing multiple things in 3 ways (see if you can find them all!).
- Syntax errors in commands now get a sensible error message.
- Tab completion now only done when the overlay is visible.
- Removes a useless loop in _Debug.findLocation.
- Uses multiple argument form of love.keyboard.isDown in _Debug.handleKey.
- Removes keyRepeat, because that shit's evil.
- Fixes "double click" bug.
- Fixes indentation.
- We now have repetitive keyboard behavior, AWESOME
- Added a new functionality that jumps you to the last output in the conole when you provide a command
- Fixed a font related bug
- Added a new functionality that enables you to jump right to the bottom of the console by pressing the middle mouse button.
- Fixed some bugs
- Added a new functionality that autocompletes the variable to the current proposal by pressing tab
- Converted to LÖVE 0.8.0
- Added a new functionality that enables you to change the 'f8' key to what you want by changing the _lovedebugpresskey='the key you want'
- Added Shift + F8 console opening, the old one still remains (Thank you miko)
- Everything except for settings (which has its own global table) is now put into the local table _Debug (Thank you tentus)
- Fixed the console to be hidden at the start
- Added _OverlayColor to global settings (see _Settings() for a list of settings) Changed location as of 1.1.5 to _DebugSettings.Settings()
- Initial version
- Attachments
-
- lovedebug.lua
- (13.19 KiB) Downloaded 156 times
Help us help you: attach a .love.
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: Debug - A whole new way of debugging your game
I agree
Hmmm, that loop was probably there for debuging, lol debugging a debugger
Oh, I didn't knew that we could do that, interesting.
BTW, I might be looking into live coding but you are free to do it too, I'm currently trying to merge both the Debug's and LICK's love.run(), at least that's what LICK's creator told me to try:
Hmmm, that loop was probably there for debuging, lol debugging a debugger
Code: Select all
love.keyboard.isDown("lshift", "rshift", "lctrl", "rctrl")
BTW, I might be looking into live coding but you are free to do it too, I'm currently trying to merge both the Debug's and LICK's love.run(), at least that's what LICK's creator told me to try:
it's not really working together because both libraries overwrite love.run - you have to build a solution that merges the two love.run.
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Debug - A whole new way of debugging your game
That would be very interesting. I'm going to bed now, so I'm not going to look into it myself today.
This update mostly makes the auto-complete much, much more awesome.
Changelog
Version 1.2.8 (Not Official) by Robin
This update mostly makes the auto-complete much, much more awesome.
Changelog
Version 1.2.8 (Not Official) by Robin
- Improves _Debug.findLocation (including: no more loadstring, no __index side-effects, finding object:methods).
- Improves _Debug.updateProposals (only valid identifiers are proposed, keywords are proposed if there is no preceding . or .
- Adds support for the home and end keys.
- Cleans up some dead code.
- Now only allows you to enter characters in ASCII, because the rest of the library handles non-ASCII unicode very poorly.
- Auto-complete now works when inserting text in the middle instead of only at the end.
- Up and down change which auto-complete option you're going to select.
- Much better drawn auto-complete options.
- Suppresses auto-complete when in the middle of an identifier.
- Brings back keyRepeat, in a way that doesn't interfere with the game.
- Fixes printing multiple things in 3 ways (see if you can find them all!).
- Syntax errors in commands now get a sensible error message.
- Tab completion now only done when the overlay is visible.
- Removes a useless loop in _Debug.findLocation.
- Uses multiple argument form of love.keyboard.isDown in _Debug.handleKey.
- Removes keyRepeat, because that shit's evil.
- Fixes "double click" bug.
- Fixes indentation.
- We now have repetitive keyboard behavior, AWESOME
- Added a new functionality that jumps you to the last output in the conole when you provide a command
- Fixed a font related bug
- Added a new functionality that enables you to jump right to the bottom of the console by pressing the middle mouse button.
- Fixed some bugs
- Added a new functionality that autocompletes the variable to the current proposal by pressing tab
- Converted to LÖVE 0.8.0
- Added a new functionality that enables you to change the 'f8' key to what you want by changing the _lovedebugpresskey='the key you want'
- Added Shift + F8 console opening, the old one still remains (Thank you miko)
- Everything except for settings (which has its own global table) is now put into the local table _Debug (Thank you tentus)
- Fixed the console to be hidden at the start
- Added _OverlayColor to global settings (see _Settings() for a list of settings) Changed location as of 1.1.5 to _DebugSettings.Settings()
- Initial version
- Attachments
-
- lovedebug.lua
- (13.21 KiB) Downloaded 143 times
Help us help you: attach a .love.
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: Debug - A whole new way of debugging your game
Found some bugs:
"Suppresses auto-complete when in the middle of an identifier." If you press tab in the middle of a word, "xpcall' will appear
If you press (exemple) "f" and then backspace it the autocomplete will stay there. (This only happens in the biggining of the input)
EDIT:
"Up and down change which auto-complete option you're going to select." Could you make it so that that only happens when there's an auto-complete on the screen, because you removed the "last command restore" functionality
"Suppresses auto-complete when in the middle of an identifier." If you press tab in the middle of a word, "xpcall' will appear
If you press (exemple) "f" and then backspace it the autocomplete will stay there. (This only happens in the biggining of the input)
EDIT:
"Up and down change which auto-complete option you're going to select." Could you make it so that that only happens when there's an auto-complete on the screen, because you removed the "last command restore" functionality
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Debug - A whole new way of debugging your game
I'll fix those.Ranguna259 wrote:Found some bugs:
"Suppresses auto-complete when in the middle of an identifier." If you press tab in the middle of a word, "xpcall' will appear
If you press (exemple) "f" and then backspace it the autocomplete will stay there. (This only happens in the biggining of the input)
It... should have that behaviour, yes. I'll check it out. (Also: you can move through history with shift+up and shift+down, even when there is an auto-complete thingy.Ranguna259 wrote:"Up and down change which auto-complete option you're going to select." Could you make it so that that only happens when there's an auto-complete on the screen, because you removed the "last command restore" functionality
EDIT: oh, I see. I forgot to release 1.2.9. Here it is:
Changelog
Version 1.2.9 (Not Official) by Robin
- Some more cleaning up of the code.
- Fixes auto-complete options not being reset in certain conditions.
- Adds a command history, navigatable with up and down arrow keys. This conflicts with selection of auto-complete options, but you can force history navigation by using shift+up and shift+down.
- Reworks error-checking in entered commands. A nice benefit is that the [string "possibly a long command"]:1: part no longer shows up, which just duplicated something that was printed right before.
- Improves _Debug.findLocation (including: no more loadstring, no __index side-effects, finding object:methods).
- Improves _Debug.updateProposals (only valid identifiers are proposed, keywords are proposed if there is no preceding . or :).
- Adds support for the home and end keys.
- Cleans up some dead code.
- Now only allows you to enter characters in ASCII, because the rest of the library handles non-ASCII unicode very poorly.
- Auto-complete now works when inserting text in the middle instead of only at the end.
- Up and down change which auto-complete option you're going to select.
- Much better drawn auto-complete options.
- Suppresses auto-complete when in the middle of an identifier.
- Brings back keyRepeat, in a way that doesn't interfere with the game.
- Fixes printing multiple things in 3 ways (see if you can find them all!).
- Syntax errors in commands now get a sensible error message.
- Tab completion now only done when the overlay is visible.
- Removes a useless loop in _Debug.findLocation.
- Uses multiple argument form of love.keyboard.isDown in _Debug.handleKey.
- Removes keyRepeat, because that shit's evil.
- Fixes "double click" bug.
- Fixes indentation.
- We now have repetitive keyboard behavior, AWESOME
- Added a new functionality that jumps you to the last output in the conole when you provide a command
- Fixed a font related bug
- Added a new functionality that enables you to jump right to the bottom of the console by pressing the middle mouse button.
- Fixed some bugs
- Added a new functionality that autocompletes the variable to the current proposal by pressing tab
- Converted to LÖVE 0.8.0
- Added a new functionality that enables you to change the 'f8' key to what you want by changing the _lovedebugpresskey='the key you want'
- Added Shift + F8 console opening, the old one still remains (Thank you miko)
- Everything except for settings (which has its own global table) is now put into the local table _Debug (Thank you tentus)
- Fixed the console to be hidden at the start
- Added _OverlayColor to global settings (see _Settings() for a list of settings) Changed location as of 1.1.5 to _DebugSettings.Settings()
- Initial version
Last edited by Robin on Thu Sep 12, 2013 9:15 am, edited 1 time in total.
Help us help you: attach a .love.
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: Debug - A whole new way of debugging your game
Command history, I was thinking of implementing that
Yep that fixed them.
lovedebug 1.3 LiveCoding™ here we go (probably gonna take a while, I still need to undestand how all it all works)
Yep that fixed them.
lovedebug 1.3 LiveCoding™ here we go (probably gonna take a while, I still need to undestand how all it all works)
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: Debug - A whole new way of debugging your game
And this needs to be updated, first glance it gives error on line 190 saying that it's trying to compar number with boolean but I think lovedebug's main game loops also needs to be updated.
EDIT: Fixed love.run() but I don't know how I'm going to fix the keys since the code's based on unicodes and 0.9.0 removed the unicode of love.keypressed(). Any ideas ? EDIT2: The keys are fixed, I'll upload the new lovedebug with a little new feature in a few hours.
EDIT: Fixed love.run() but I don't know how I'm going to fix the keys since the code's based on unicodes and 0.9.0 removed the unicode of love.keypressed(). Any ideas ? EDIT2: The keys are fixed, I'll upload the new lovedebug with a little new feature in a few hours.
- Ranguna259
- Party member
- Posts: 911
- Joined: Tue Jun 18, 2013 10:58 pm
- Location: I'm right next to you
Re: Debug - A whole new way of debugging your game
YOU CAN NOW DO LIVE CODING WITH LÖVE !!!!
It is finaly done, live coding with LÖVE is now possible thanks to lovedebug
Added to GitHub.
Things that need to be done: add 'ERROR' prefixes to the errors that appear when reloading the code.
Changelog
Version 1.3 (Not Official) by Ranguna259
It is finaly done, live coding with LÖVE is now possible thanks to lovedebug
Added to GitHub.
Things that need to be done: add 'ERROR' prefixes to the errors that appear when reloading the code.
Changelog
Version 1.3 (Not Official) by Ranguna259
- Converted to LÖVE 0.9.0
- To jump to the bottom of the console you now have to press lCtrl+middle mouse buttons instead of just the middle mouse button.
- You can now do code hotswapping by accessing the console and by pressing the F5 button.
- Added two new variables to _DebugSettings, 'LiveFile' and 'LiveReset', see _DebugSettings.Settings() for more information.
- Some more cleaning up of the code.
- Fixes auto-complete options not being reset in certain conditions.
- Adds a command history, navigatable with up and down arrow keys. This conflicts with selection of auto-complete options, but you can force history navigation by using shift+up and shift+down.
- Reworks error-checking in entered commands. A nice benefit is that the [string "possibly a long command"]:1: part no longer shows up, which just duplicated something that was printed right before.
- Improves _Debug.findLocation (including: no more loadstring, no __index side-effects, finding object:methods).
- Improves _Debug.updateProposals (only valid identifiers are proposed, keywords are proposed if there is no preceding . or :).
- Adds support for the home and end keys.
- Cleans up some dead code.
- Now only allows you to enter characters in ASCII, because the rest of the library handles non-ASCII unicode very poorly.
- Auto-complete now works when inserting text in the middle instead of only at the end.
- Up and down change which auto-complete option you're going to select.
- Much better drawn auto-complete options.
- Suppresses auto-complete when in the middle of an identifier.
- Brings back keyRepeat, in a way that doesn't interfere with the game.
- Fixes printing multiple things in 3 ways (see if you can find them all!).
- Syntax errors in commands now get a sensible error message.
- Tab completion now only done when the overlay is visible.
- Removes a useless loop in _Debug.findLocation.
- Uses multiple argument form of love.keyboard.isDown in _Debug.handleKey.
- Removes keyRepeat, because that shit's evil.
- Fixes "double click" bug.
- Fixes indentation.
- We now have repetitive keyboard behavior, AWESOME
- Added a new functionality that jumps you to the last output in the conole when you provide a command
- Fixed a font related bug
- Added a new functionality that enables you to jump right to the bottom of the console by pressing the middle mouse button.
- Fixed some bugs
- Added a new functionality that autocompletes the variable to the current proposal by pressing tab
- Converted to LÖVE 0.8.0
- Added a new functionality that enables you to change the 'f8' key to what you want by changing the _lovedebugpresskey='the key you want'
- Added Shift + F8 console opening, the old one still remains (Thank you miko)
- Everything except for settings (which has its own global table) is now put into the local table _Debug (Thank you tentus)
- Fixed the console to be hidden at the start
- Added _OverlayColor to global settings (see _Settings() for a list of settings) Changed location as of 1.1.5 to _DebugSettings.Settings()
- Initial version
- Attachments
-
- lovedebug.lua
- lovedebug 1.3
- (15.81 KiB) Downloaded 178 times
Who is online
Users browsing this forum: No registered users and 5 guests