Tutorial Ren'Py Enabling Developer & Command Consoles In Ren'py

matrix2

Member
Mar 15, 2019
452
114
When enabled, you can use the variable viewer in the developer console (Shift-D) to find variables in the game. You can use the game console (Shift-O) to edit the variables.

Getting the name right is critical, so I recommend the following. Let's assume that there's a variable named "Fred" In the console, if you type "Fred" and return, it will show the current value of Fred. If you mistype, e.g., 'Fref', you get an error message. If you attempt to change the value of a wrongly named variable you will either edit the wrong variable (if it is defined) or create a new variable with the given value. Either could cause unknown and serious consequences at some point.

When you have the name correct, you can use the up/down arrows to navigate through your entries back to the Fred entry and edit it by appending, e.g., "=5", "+=2","-=3", etc. to modify the value. This way, you are guaranteed to not accidentally edit the wrong variable or create a new variable. For example:

Code:
>Fref
NameError: name 'Fref' is not defined
>Fred
3
>Fred=5
>Fred
5
>Fred+=2
>Fred
7
>Fred-=3
>Fred
3
can u tell me for the cheat for the money please ?
 

AtotehZ

Well-Known Member
Aug 24, 2018
1,885
1,245
can u tell me for the cheat for the money please ?
The variable for any currency in a Ren'Py game is what the developer defined it as. It could be anything.

I don't know how to look up variables in the game, but I do know how to sleuth a bit.

1) Make a copy of the game in windows (to avoid affecting the original game folder)
2) In that copy use unren to unpack and decrypt files
3) In the game copy search for *.rpy
4) Add all results to notepad++
5) Press search(ctrl+f)
6) Put in common phrases like cash, money, coin, $ cash and similar and search with "Find all in all opened documents"
7) Look at the different results at the bottom and deduce when the code, not the characters, are talking about having money

As an example I recently played a game where I found out the currencies were bag_cash, bag_gems and so on..
I input bag_cash = 99999 or bag_gems = 9999 in dev console and that was that.

Beware though. Some values could mess up your save depending on the game. Also, capitalization matters, get it wrong and it won't work
In other words: Moneymoney.

EDIT: Typos, wrote original post in bed at 2AM on mobile and my fingers are massive.
 
Last edited:

anne O'nymous

I'm not grumpy, I'm just coded that way.
Modder
Respected User
Donor
Jun 10, 2017
10,110
14,787
I don't know how to look up variables in the game, but I do know how to sleuth a bit.
Open the developer console with shift + d then choose "Variable Viewer".
If the place where the money (or any other information) have been defined as a variable and not as part of an object, you'll see its name and actual value in the list.
 
Last edited:
  • Like
Reactions: Zwart and AtotehZ

bradley7creeper

New Member
May 17, 2021
1
0
Hi new to the game and a friend recommended it to me but is there a way to cheat for a lot of money in BlueStacks, and if there is how?
 

Radoslaw Wolf

Well-Known Member
May 23, 2017
1,863
5,709
Open the developer console with shift + d then choose "Variable Viewer".
If the place where the money (or any other information) have been defined as a variable and not as part of an object, you'll see its name and actual value in the list.
I have a problem, the list won't scroll on me...
 

ace5094

Newbie
May 29, 2019
17
2
Let's make a new rule when people sign up for this site that if they make a post in any game thread that contains the text "how do you configure the console?" their ip gets banned for life or shot out of a cannon. Make it a form that they have to literally check a box and select I agree to continue. Seriously this question has been asked and answered on virtually every single page of every friggin' ren'py game thread.
i didnt know the console was a thing until recently so no rule like that
 

l1pp13jm

Newbie
Oct 22, 2019
25
14
And perhaps that the lack of answer is an answer by itself...

But since you ask so nicely :


Basically speaking :
  1. You extract the APK archive ;
  2. You restore the files names to their none "x-" leading names ;
  3. You edit the renpy/common/00console.rpy file like said in OP ;
  4. You use the SDK to generate a new APK version of the game.

And then you'll be able to tell me if the console is still unavailable in Android ports, since it's 100% useless without a keyboard.
i have several question if you dont mind

extract like run and download the game?
Restore? what does this mean?
SDK?

Im not very tech literate but i do wanna try
thank you
 

anne O'nymous

I'm not grumpy, I'm just coded that way.
Modder
Respected User
Donor
Jun 10, 2017
10,110
14,787
extract like run and download the game?
No, extract like "open the APK archive and extract the files from this archive".


Restore? what does this mean?
Exactly what I wrote, remove the leading "x-" from the files name.


Software Development Kit, Ren'py's one can be found .


But honestly, if you have to ask the first two questions, then you shouldn't do it.
There's no shame in not understanding what I initially wrote, but it's basic language talking about basic computer steps/concepts. Therefore, if you don't understand it by yourself, you'll be even more lost during the rest of the process. It's like anything else that is at least a bit technical ; if you don't understand the language, let's a specialist do it because you've more risks to break everything than chances to succeed.
 
  • Like
Reactions: l1pp13jm

l1pp13jm

Newbie
Oct 22, 2019
25
14
No, extract like "open the APK archive and extract the files from this archive".




Exactly what I wrote, remove the leading "x-" from the files name.




Software Development Kit, Ren'py's one can be found .


But honestly, if you have to ask the first two questions, then you shouldn't do it.
There's no shame in not understanding what I initially wrote, but it's basic language talking about basic computer steps/concepts. Therefore, if you don't understand it by yourself, you'll be even more lost during the rest of the process. It's like anything else that is at least a bit technical ; if you don't understand the language, let's a specialist do it because you've more risks to break everything than chances to succeed.
Yeah you're probably

I'll go learn some more before trying anything

Thanks for the reply
 

us100

New Member
Aug 22, 2020
1
0
I'm having so much trouble opening the console on mac, I changed config.console to True but the console won't appear when I hit Shift + O (I'm on Milfy City btw). Please let me know if there's any suggestions or things I should do to troubleshoot
 

krinekron

Member
Feb 19, 2018
249
167
i have:

renpy.call_screen("_variable_viewer", all_entries=entries, deleted_entries=deleted_entries)
return
change to this? :

renpy.call_screen("_variable_viewer", entries=sorted(entries))
return
 

AnubisZero

New Member
May 22, 2023
13
18
I typically assign 'dir()' to a variable, let's say 'dirVars', then do a 'print dirVars' to make sure it all worked fine.

It seems not all versions of Ren'py allow this behavior. a 'print dirVars' comes back with 'None'

any suggestions or alternatives?
 

Tlaero

Active Member
Game Developer
Nov 24, 2018
999
4,919
Anyone know the command to load a specific scene?
Are you asking about jumping to a label from within the debugger/console?

If you have a label called "myscene" then from the shift + o console type:

jump myscene

at the > prompt.

Tlaero
 
  • Like
Reactions: Carrnage