#==============================================================================
# F07 - 地图窗口 - By芙蕾娅
#------------------------------------------------------------------------------
# ★ - 新增 ☆ - 修改 ■ - 删除 ● - 无变更
#==============================================================================
module Freya
# 0 = 只显示文字
# 1 = 只显示图片
# 2 = 显示文字和图片
ShowType = 0
end
#==============================================================================
# ■ Window_Menu_Map_Name
#------------------------------------------------------------------------------
# 显示目前所在地的窗口
#==============================================================================
class Window_Menu_Map_Name < Window_Base
#--------------------------------------------------------------------------
# ● 初始化对象
#--------------------------------------------------------------------------
def initialize
super(0, 0, window_width, fitting_height(1))
refresh
end
#--------------------------------------------------------------------------
# ● 获取窗口的宽度
#--------------------------------------------------------------------------
def window_width
return 160
end
#--------------------------------------------------------------------------
# ● 刷新
#--------------------------------------------------------------------------
def refresh
contents.clear
if Freya::ShowType == 0
draw_text(contents.rect, $game_map.display_name, 1)
elsif Freya::ShowType == 1
bitmap = Cache.system("MAP_#{$game_map.map_id}")
rect = Rect.new(0,0,bitmap.width,bitmap.height)
contents.blt(x, y, bitmap, rect)
else
bitmap = Cache.system("MAP_#{$game_map.map_id}")
rect = Rect.new(0,0,bitmap.width,bitmap.height)
contents.blt(x, y, bitmap, rect)
draw_text(contents.rect, $game_map.display_name, 1)
end
end
end
#==============================================================================
# ■ Scene_Menu
#------------------------------------------------------------------------------
# 菜单画面
#==============================================================================
class Scene_Menu < Scene_MenuBase
#--------------------------------------------------------------------------
# ● 生成金钱窗口
#--------------------------------------------------------------------------
alias create_map_window create_gold_window
def create_gold_window
create_map_window
@map_window = Window_Menu_Map_Name.new
@command_window.y = @map_window.height
end
end