Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

How are variables we use in RPGXP represented in RGSS?

I need to know how I can use a Variable thats value is assigned by a common event in script form. I thought it would be as simple as "\V[0009]" but after two days of playing aroud I can't get the script to acknoldge my Variables.
 
This is very simple. All you have to do to obtain a variable from events is using this line:
Code:
$game_variables[number]
So if you want to use variable number 0009 as you used in your first post, simply type:
Code:
$game_variables[9]
You can also set values this way, even to strings if you want:
Code:
$game_variables[9] = 5
$game_variables[10] = "Hello world"

Hope this helps.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top