Hmm... If it for the minimap such as Mr.Moes SBABS, you should name that map Act II- Chapter V.jjangjae":1cp66k2u said:Uh, I was talking about the Act and Chapter numbers appearing in the HUD
Samhatake":2vxkz8wa said:Hmm... If it for the minimap such as Mr.Moes SBABS, you should name that map Act II- Chapter V.jjangjae":2vxkz8wa said:Uh, I was talking about the Act and Chapter numbers appearing in the HUD
WHat I do is add a Batch of Act/Chapater Maps and put the maps in there
#==============================================================================
class Window_KHUD < Window_Base
def initialize
super(440, 350, 200, 130)
self.contents = Bitmap.new(width - 32, height - 32)
self.back_opacity = 145 #Change to 0 if you use a picture
refresh
end
def refresh
self.contents.clear
#Uncomment these lines if you want a picture instead of window
# bitmap = RPG::Cache.picture("khud")
# self.contents.blt(0, 0, bitmap, Rect.new(0, 10, 175, 175))
# Displays Gold, Map, and unchanged words
self.contents.font.size = 14
self.contents.font.color = normal_color
self.contents.draw_text(-32, 54, 120, 32, $game_party.gold.to_s, 2)
#Show Map Name
map_infos = load_data("Data/MapInfos.rxdata")
name = map_infos[$game_map.map_id].name.to_s
self.contents.draw_text(28, 22, 400, 32, name.to_s)
self.contents.font.color = system_color
self.contents.draw_text(-96, 54, 120, 32, $data_system.words.gold, 2)
self.contents.draw_text(0, 22, 120, 32, "Map")
self.contents.draw_text(0, 38, 120, 32, "Status")
reset_variables
return if !@actor
# Displays actors state, level, EXP and name
draw_actor_level(@actor, 0, 6)
draw_actor_state(@actor, 44, 38, width = 120)
self.contents.font.size = 18
draw_actor_name(@actor, 0, -10)
self.contents.font.size = 14
self.contents.font.color = system_color
self.contents.draw_text(72, 6, 48, 32, "EXP")
self.contents.font.color = normal_color
self.contents.draw_text(76, 6, 84, 32, @actor.exp_s, 2)
end
def reset_variables
@actor = $game_party.actors[0]
@old_level = @actor ? @actor.level : 0
@old_exp = @actor ? @actor.exp : 0
end
def update
super
refresh if (@actor = $game_party.actors[0] or
@old_level = @actor ? @actor.level : 0 or
@old_exp = @actor ? @actor.exp : 0 )
end
end
class Scene_Map
alias khud_main main
alias khud_update update
def main
@khud = Window_KHUD.new
khud_main
@khud.dispose
end
def update
@khud.update
khud_update
end
end
jjangjae":2m8vowih said:Well, I would like it like this:
It would read (after the row that says Gold--
Act [Number of Act]
Chapter [Number of Chapter]
#==============================================================================
class Game_System
attr_accessor :act
attr_accessor :chapter
alias old_init initialize
def initialize
old_init
@act = 1
@chapter = 1
end
end
class Window_KHUD < Window_Base
def initialize
super(440, 340, 200, 140)
self.contents = Bitmap.new(width - 32, height - 32)
self.back_opacity = 145 #Change to 0 if you use a picture
refresh
end
def refresh
self.contents.clear
#Uncomment these lines if you want a picture instead of window
# bitmap = RPG::Cache.picture("khud")
# self.contents.blt(0, 0, bitmap, Rect.new(0, 10, 175, 175))
# Displays Gold, Map, and unchanged words
self.contents.font.size = 14
self.contents.font.color = normal_color
self.contents.draw_text(44, 54, 120, 32, $game_party.gold.to_s)
#Show Map Name
map_infos = load_data("Data/MapInfos.rxdata")
name = map_infos[$game_map.map_id].name.to_s
self.contents.draw_text(44, 22, 400, 32, name.to_s)
self.contents.font.color = system_color
self.contents.draw_text(0, 54, 120, 32, $data_system.words.gold)
self.contents.draw_text(0, 22, 120, 32, "Map")
self.contents.draw_text(0, 38, 120, 32, "Status")
reset_variables
return if !@actor
# Displays actors state, level, EXP and name
draw_actor_level(@actor, 0, 6)
draw_actor_state(@actor, 44, 38, width = 120)
self.contents.font.size = 18
draw_actor_name(@actor, 0, -10)
self.contents.font.size = 14
self.contents.font.color = system_color
self.contents.draw_text(72, 6, 48, 32, "EXP")
self.contents.font.color = normal_color
self.contents.draw_text(76, 6, 84, 32, @actor.exp_s, 2)
self.contents.font.color = system_color
# Displays current act and chapter
self.contents.draw_text(0, 70, 120, 32, "Act")
self.contents.font.color = normal_color
self.contents.draw_text(44, 70, 120, 32, $game_system.act.to_s)
self.contents.font.color = system_color
self.contents.draw_text(0, 86, 120, 32, "Chapter")
self.contents.font.color = normal_color
self.contents.draw_text(44, 86, 120, 32, $game_system.chapter.to_s)
end
def reset_variables
@actor = $game_party.actors[0]
@old_level = @actor ? @actor.level : 0
@old_exp = @actor ? @actor.exp : 0
end
def update
super
refresh if (@actor = $game_party.actors[0] or
@old_level = @actor ? @actor.level : 0 or
@old_exp = @actor ? @actor.exp : 0 )
end
end
class Scene_Map
alias khud_main main
alias khud_update update
def main
@khud = Window_KHUD.new
khud_main
@khud.dispose
end
def update
@khud.update
khud_update
end
end
$game_system.act = #
$game_system.chapter = #
It still uses the system word for gold, which means that it must have been changed in your project. Go into the system tab of the database, and check to see if the system word for gold has been changed. (It is under "G (currency):")jjangjae":33tyx64c said:It's great. I don't see the gold but that's okay though I do wonder why in place of gold it says "id". I'm not sure if that was supposed to be part of an object id or what not.
jjangjae":2s6oqt1s said:I know. I checked again and the currency I listed still does not show in-game for the HUD, it still says "id".
contents.draw_text(44, 54, 120, 32, $game_party.gold.to_s)
contents.draw_text(0, 54, 120, 32, $data_system.words.gold)