class Window_Hud < Window_Base
ID = 10
def initialize
super(0, 0, 160, 64)
self.contents = Bitmap.new(128, 32)
refresh
end
def refresh
@value = $game_variables[ID]
contents.clear
contents.draw_text(0, 0, 128, 32, @value.to_s)
end
def update
refresh if @value != $game_variables[ID]
end
end
class Scene_Map
alias main1 main
alias update1 update
def main
@hud = Window_Hud.new
main1
@hud.dispose
end
def update
@hud.dispose
update1
end
end