How to skip straight to a section of code for faster debugging?
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
How to skip straight to a section of code for faster debugging?
Please recommend some tips for skipping straight to a section of code for faster debugging purposes? Any tips and tricks? Currently I start up my renpy project from beginning, click start, go to the section in the game that needs testing, but is there a better way?
- Imperf3kt
- Lemma-Class Veteran
- Posts: 3785
- Joined: Mon Dec 14, 2015 5:05 am
- itch: Imperf3kt
- Location: Your monitor
- Contact:
Re: How to skip straight to a section of code for faster debugging?
Place some dummy labels you can jump to or call.
Right-click on the skip button to use fast skip mode.
I think the developer console may have some other options for this, too. Access it by pressing CTRL D while testing your game. Or was it shift D...
Right-click on the skip button to use fast skip mode.
I think the developer console may have some other options for this, too. Access it by pressing CTRL D while testing your game. Or was it shift D...
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.
Current project: GGD Mentor
Twitter
pro·gram·mer (noun) An organism capable of converting caffeine into code.
Current project: GGD Mentor
- Remix
- Eileen-Class Veteran
- Posts: 1628
- Joined: Tue May 30, 2017 6:10 am
- Completed: None... yet (as I'm still looking for an artist)
- Projects: An un-named anime based trainer game
- Contact:
Re: How to skip straight to a section of code for faster debugging?
--warp
win+r, type cmd, press enter, cd to the launcher folder, type renpy.exe my_project --warp script.rpy:458
with that you'd likely want a bespoke after_warp label to setup variables and the like.
In most instances, you are likely going to save more time than it takes to code by adding a developer navigation screen that lists all the possible labels and allows tweaking of known variables...
Either path basically comes down to the twixt that, "without playing through the game, jumping to an arbitrary label/line cannot/does not know if it should adjust any internal variables"
win+r, type cmd, press enter, cd to the launcher folder, type renpy.exe my_project --warp script.rpy:458
with that you'd likely want a bespoke after_warp label to setup variables and the like.
In most instances, you are likely going to save more time than it takes to code by adding a developer navigation screen that lists all the possible labels and allows tweaking of known variables...
Either path basically comes down to the twixt that, "without playing through the game, jumping to an arbitrary label/line cannot/does not know if it should adjust any internal variables"
Frameworks & Scriptlets:
- Speech Bubble dialogue system
- Multiple Notify with ATL and history
- (WIP) Radial Masking - needs updating to use Shader
- 7.4 - Smooth Tinting using ATL and matrixcolor
- Several other repositories there too
- trooper6
- Lemma-Class Veteran
- Posts: 3712
- Joined: Sat Jul 09, 2011 10:33 pm
- Projects: A Close Shave
- Location: Medford, MA
- Contact:
Re: How to skip straight to a section of code for faster debugging?
When your game starts, type Shift+O to get to the console.
From the console you can just type in jump commands, like "jump label_I_want_to_test"
You can also set specific variable from the console as well. I've used setting variables and jumping to labels to test things often.
From the console you can just type in jump commands, like "jump label_I_want_to_test"
You can also set specific variable from the console as well. I've used setting variables and jumping to labels to test things often.
A Close Shave:
*Last Thing Done (Aug 17): Finished coding emotions and camera for 4/10 main labels.
*Currently Doing: Coding of emotions and camera for the labels--On 5/10
*First Next thing to do: Code in all CG and special animation stuff
*Next Next thing to do: Set up film animation
*Other Thing to Do: Do SFX and Score (maybe think about eye blinks?) Check out My Clock Cookbook Recipe: http://lemmasoft.renai.us/forums/viewto ... 51&t=21978
*Last Thing Done (Aug 17): Finished coding emotions and camera for 4/10 main labels.
*Currently Doing: Coding of emotions and camera for the labels--On 5/10
*First Next thing to do: Code in all CG and special animation stuff
*Next Next thing to do: Set up film animation
*Other Thing to Do: Do SFX and Score (maybe think about eye blinks?) Check out My Clock Cookbook Recipe: http://lemmasoft.renai.us/forums/viewto ... 51&t=21978
Who is online
Users browsing this forum: Bing [Bot], Google [Bot], Semrush [Bot]