Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Advanced Gold Display
#1
This is a locked, single-post thread from Creation Asylum. Archived here to prevent its loss.
No support is given. If you are the owner of the thread, please contact administration.


In RMXP, the gold display is simple, as if you have 1256456 GP , it will display just like that. I made a script that will show the gold like this:

1,256,456 GP

It's better, it's more easily read. If you want it, simply replace the entire REFRESH method of your window_gold with the following script:
Code:
def refresh

   #Advanced Gold Display mini-script by Dubealex.

   self.contents.clear
      
   case $game_party.gold
     when 0..9999
       gold = $game_party.gold
     when 10000..99999
       gold = $game_party.gold.to_s
       array = gold.split(//)
       gold = array[0].to_s+array[1].to_s+","+array[2].to_s+array[3].to_s+array[4].to_s
     when 100000..999999
       gold = $game_party.gold.to_s
       array = gold.split(//)
       gold = array[0].to_s+array[1].to_s+array[2].to_s+","+array[3].to_s+array[4].to_s+array[5].to_s
     when 1000000..9999999
       gold = $game_party.gold.to_s
       array = gold.split(//)
       gold = array[0].to_s+","+array[1].to_s+array[2].to_s+array[3].to_s+","+array[4].to_s+array[5].to_s+array[6].to_s
     end
  
   self.contents.font.color = text_color(6)
   gold_word = $data_system.words.gold.to_s + ":"
   cx = contents.text_size(gold_word).width
   cx2=contents.text_size(gold.to_s).width
   self.contents.draw_text(4, 0, 120-cx-2, 32, gold_word)
   self.contents.font.color = text_color(0)
   self.contents.draw_text(124-cx2+2, 0, cx2, 32, gold.to_s, 2)
end
end

You can use the color you want for the text, just change the number between parenthesis in the lines:

Code:
self.contents.font.color = text_color(6)



By the color you want.

(i.e: This will do as the command \c[ID] from a message box.)
}


Possibly Related Threads…
Thread Author Replies Views Last Post
  Display a gold window on the map Chronic_NG 0 2,731 12-04-2006, 01:00 PM
Last Post: Chronic_NG
  Advanced Command Windows Tsunokiette 0 2,321 07-07-2006, 01:00 PM
Last Post: Tsunokiette
  SIBruno AES - Advanced Equip Screen sibruno 0 2,368 02-10-2006, 01:00 PM
Last Post: sibruno
  SIBruno Advanced Equip Screen v2 sibruno 0 1,969 01-30-2006, 01:00 PM
Last Post: sibruno
  Advanced Title Screen 2 kaito 0 2,315 09-19-2005, 01:00 PM
Last Post: kaito
  Different Gold Window Sheol 0 2,177 09-01-2005, 01:00 PM
Last Post: Sheol
  ATS - Advanced Time System R1 Dubealex 0 2,142 03-08-2005, 01:00 PM
Last Post: Dubealex



Users browsing this thread: