$ Symbol in Ren'py
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.
- RedArTWOrks2
- Newbie
- Posts: 7
- Joined: Thu Feb 19, 2015 8:15 am
- Contact:
$ Symbol in Ren'py
Hello everybody.
Today I have a question that doesn't prevent me from programming, but I just want to ask to know it.
My question is related with the function of "$ symbol in ren'py codes", for what is it used for? And what is the difference between a code with that symbol and another without it?
Thanks
RedArTWOrks
Today I have a question that doesn't prevent me from programming, but I just want to ask to know it.
My question is related with the function of "$ symbol in ren'py codes", for what is it used for? And what is the difference between a code with that symbol and another without it?
Thanks
RedArTWOrks
- Dylan_Bain
- Regular
- Posts: 101
- Joined: Mon Mar 09, 2015 2:05 pm
- Organization: Dylan Bain Games
- Location: Scotland
- Contact:
Re: $ Symbol in Ren'py
It is used to define variables.
For example=
or
You can find out more about $ variables at http://renpy.org/wiki/renpy/doc/tutoria ... er_Choices.
For example=
Code: Select all
$ variable1 = FalseCode: Select all
$ variable1 == True- RedArTWOrks2
- Newbie
- Posts: 7
- Joined: Thu Feb 19, 2015 8:15 am
- Contact:
Re: $ Symbol in Ren'py
Thank you so much 
- trooper6
- Lemma-Class Veteran
- Posts: 3712
- Joined: Sat Jul 09, 2011 10:33 pm
- Projects: A Close Shave
- Location: Medford, MA
- Contact:
Re: $ Symbol in Ren'py
Actually, $ means that the line is a single line of Python code. While this is often used to assign variables, I regularly use it to do other things as well, for example calling methods.
Doing a quick search of the documentation produces two pages (one in QuickStart) that explain this:
http://www.renpy.org/doc/html/python.ht ... -statement
http://www.renpy.org/doc/html/quickstar ... statements
Doing a quick search of the documentation produces two pages (one in QuickStart) that explain this:
http://www.renpy.org/doc/html/python.ht ... -statement
http://www.renpy.org/doc/html/quickstar ... statements
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
- PyTom
- Ren'Py Creator
- Posts: 15893
- Joined: Mon Feb 02, 2004 10:58 am
- Completed: Moonlight Walks
- Projects: Ren'Py
- IRC Nick: renpytom
- Github: renpytom
- itch: renpytom
- Location: Kings Park, NY
- Contact:
Re: $ Symbol in Ren'py
Basically,
is shorthand for:
Code: Select all
$ line of python code
Code: Select all
python:
line of python code
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom(When was the last time you backed up your game?)
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom
Who is online
Users browsing this forum: Bing [Bot], Google [Bot]

