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.

Need help to show variable

I'm using one of L's Custom Menu Scripts (This one to be exactly: http://www.rmxp.org/forums/http://dev.r ... 31#p568831)

She says you could show a variable here:

Code:
    #Draw Variable
    self.contents.font.color = system_color
    self.contents.draw_text(412,0,120,32,'Variable Name:')
    self.contents.font.color = normal_color
    self.contents.draw_text(540,0,120,32,'Variable')
  end

But I'm a total noob at scripting and i would like some help with this so I can show Variable [100] here.  :tongue2:
 
replace
Code:
self.contents.draw_text(540,0,120,32,'Variable')
with
Code:
self.contents.draw_text(540,0,120,32,$game_variables[v_id])
v_id is the ID of your variable.

Hope it helps!
-Dargor
 
Thanks but it doesn't seem to work. I also use the Tons-Of-Addons Scripts from Blizzard and when I open the CMS it says:
Code:
??? 'Tons_Addons_1'? 1744 ??? Type Error????
  cannot convert Fixnum into String
Do you know how to fix this?  :dead:
 

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