Chaos Project

RPG Maker => RPG Maker Scripts => Script Troubleshooting => Topic started by: sasofrass on June 25, 2011, 05:48:25 pm

Title: [XP] Simple issue I can't figure out
Post by: sasofrass on June 25, 2011, 05:48:25 pm
zzz

Basically, I'd like to display variables in the status menu and I can't figure this one out - I've googled and the answer was probably there but I failed to find it.

self.contents.draw_text(220+155, 280, 200, 32, $game_variables[1] + " / 5")

What am I doing wrong :(
Title: Re: [XP] Simple issue I can't figure out
Post by: ForeverZer0 on June 25, 2011, 06:26:59 pm
Unless $game_variables[5] is a string, which it is likely not, this won't work.
Add a ".to_s" on it so that it is $game_variables[5].to_s

Or use this line:

self.contents.draw_text(375, 280, 200, 32, "#{$game_variables[5]} /5")