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.

Simple script request

Hello. This isn't really much of a script request as a line of code request lol. Instead of showing gp for money on the menu, I want it to be a 24x24 icon of a coin (of coarse the icon would be made by me). So, I would like to know the line of the code on the menu I need to change along with what I need to replace it with. I'm sure any master (or probably noob lol) scripter could tell me this. so plz can someone tell me? lol (I'm using the standard menu for rmxp, so theres nothing special about it.)
 
I'll post you one later cause the one i'm using works only with my menu it won't take long till i find the line on my other project.

[Edit]

Found it but i couldn't remove the world G with the script you must remove it manualy go in database,system and in G currency leave it blank thats all.

Paste it under window_gold i named it window_gold edit(you can name it what you want):

Code:
class Window_Gold < Window_Base
  alias vd_orig_ini initialize
  
  def initialize
    @updates = 0
    @coin_bitmap = RPG::Cache.picture('gold')
    vd_orig_ini
    self.contents.blt(107, 5, @coin_bitmap, Rect.new(0, 0, 25, 32))
  end
end

Right now it's gold the picture it's finding change it to wathever you want and the icon must be in the pictures folder thats all.
 
Actually, to remove "G" phrase in the script, besides emptying the Gold phrase in the database, you can remove these lines found in class Window_Gold, method initialize:
Code:
    self.contents.font.color = system_color
    self.contents.draw_text(124-cx, 0, cx, 32, $data_system.words.gold, 2)

And by the way, it's a little bit odd to draw something in initialize method, although the outcome is the same :)
 
Just incase if I wanted more than 24x24 or less, do you have the part of the code that makes it like that (I think I could find this myself lol, but just wondering if its possible)
 
The other one it's edited in window_gold cause it's in another project and you will need to move the numbers to make it work.

But i can try although i know little script on the one i posted you, you want to show the currency i mean 0 for the gold ecc too?
 
Sorry for posting this late but i didn't have internet these past days.

As for the script if someone makes it to you it would be better i don't have time and i know little scripting i couldn't show more then one icon. Sorry
 

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