Difference between revisions of "Declaring Variables"
Jump to navigation
Jump to search
Aliases - "int" and "long" for "short", "reference" for "ref"
imported>PoHa! (changed all instances of "Int" to the correct syntax of "Short") |
imported>Cipscis (Aliases - "int" and "long" for "short", "reference" for "ref") |
||
Line 8: | Line 8: | ||
float myFloatVariable | float myFloatVariable | ||
</pre> | </pre> | ||
"Short" variables can also be declared with the keywords "long" and "int", and "ref" variables can use the keyword "reference". | |||
A local variable can be placed anywhere within the script code, it only needs to be declared before the first command that uses it. Usually you declare all variables on top of the script, though, to improve the script's readability. | A local variable can be placed anywhere within the script code, it only needs to be declared before the first command that uses it. Usually you declare all variables on top of the script, though, to improve the script's readability. |