asiuoretusoprtghuisdg
This commit is contained in:
parent
bbb4d4fc27
commit
9c8460a245
|
|
@ -77,7 +77,7 @@ set(scripts
|
||||||
i18n_English.rb
|
i18n_English.rb
|
||||||
i18n_Japanese.rb
|
i18n_Japanese.rb
|
||||||
i18n_Language.rb
|
i18n_Language.rb
|
||||||
Window_TPtL
|
Window_TPtL.rb
|
||||||
Settings.rb)
|
Settings.rb)
|
||||||
|
|
||||||
find_program(RUBY_EXE ruby
|
find_program(RUBY_EXE ruby
|
||||||
|
|
|
||||||
|
|
@ -45,7 +45,8 @@ class Game_Temp
|
||||||
attr_accessor :menu_calling # menu calling flag
|
attr_accessor :menu_calling # menu calling flag
|
||||||
attr_accessor :item_menu_calling # item menu calling flag
|
attr_accessor :item_menu_calling # item menu calling flag
|
||||||
attr_accessor :travel_menu_calling # fast travel menu calling flag
|
attr_accessor :travel_menu_calling # fast travel menu calling flag
|
||||||
attr_accessor :window_settings_calling # fast travel menu calling flag
|
attr_accessor :window_settings_calling # fast travel menu calling flag
|
||||||
|
attr_accessor :window_debug_calling # fast travel menu calling flag
|
||||||
attr_accessor :menu_beep # menu: play sound effect flag
|
attr_accessor :menu_beep # menu: play sound effect flag
|
||||||
attr_accessor :save_calling # save calling flag
|
attr_accessor :save_calling # save calling flag
|
||||||
attr_accessor :debug_calling # debug calling flag
|
attr_accessor :debug_calling # debug calling flag
|
||||||
|
|
@ -106,6 +107,7 @@ class Game_Temp
|
||||||
@item_menu_calling = false
|
@item_menu_calling = false
|
||||||
@travel_menu_calling = false
|
@travel_menu_calling = false
|
||||||
@window_settings_calling = false
|
@window_settings_calling = false
|
||||||
|
@window_debug_calling = false
|
||||||
@menu_beep = false
|
@menu_beep = false
|
||||||
@save_calling = false
|
@save_calling = false
|
||||||
@debug_calling = false
|
@debug_calling = false
|
||||||
|
|
|
||||||
|
|
@ -51,6 +51,7 @@ class Scene_Map
|
||||||
# Make fast travel menu
|
# Make fast travel menu
|
||||||
@fast_travel = FastTravel.new
|
@fast_travel = FastTravel.new
|
||||||
@window_settings = Window_Settings.new
|
@window_settings = Window_Settings.new
|
||||||
|
@window_debug = Window_TPtL.new
|
||||||
# Fade to black transition
|
# Fade to black transition
|
||||||
@blackfade = Sprite.new
|
@blackfade = Sprite.new
|
||||||
@blackfade.bitmap = Bitmap.new(Graphics.width, Graphics.height)
|
@blackfade.bitmap = Bitmap.new(Graphics.width, Graphics.height)
|
||||||
|
|
@ -86,7 +87,8 @@ class Scene_Map
|
||||||
@menu.dispose
|
@menu.dispose
|
||||||
@item_menu.dispose
|
@item_menu.dispose
|
||||||
@fast_travel.dispose
|
@fast_travel.dispose
|
||||||
@window_settings.dispose
|
@window_settings.dispose
|
||||||
|
@window_debug.dispose
|
||||||
# Dispose of item icon
|
# Dispose of item icon
|
||||||
@item_icon.dispose
|
@item_icon.dispose
|
||||||
@item_icon_flash.dispose
|
@item_icon_flash.dispose
|
||||||
|
|
@ -147,7 +149,7 @@ class Scene_Map
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
$game_system.map_interpreter.update
|
$game_system.map_interpreter.update
|
||||||
$game_temp.menus_visible = @menu.visible || @item_menu.visible || @fast_travel.visible || @window_settings.visible
|
$game_temp.menus_visible = @menu.visible || @item_menu.visible || @fast_travel.visible || @window_settings.visible || @window_debug.visible
|
||||||
$game_player.update
|
$game_player.update
|
||||||
$game_followers.each{|f| f.update}
|
$game_followers.each{|f| f.update}
|
||||||
# Update system (timer), screen
|
# Update system (timer), screen
|
||||||
|
|
@ -196,13 +198,13 @@ class Scene_Map
|
||||||
@item_icon.bitmap = nil
|
@item_icon.bitmap = nil
|
||||||
@item_icon_flash.bitmap = nil
|
@item_icon_flash.bitmap = nil
|
||||||
else
|
else
|
||||||
name = $data_items[@item_id].icon_name
|
name = $data_items[@item_id].icon_name
|
||||||
translation_name = "#{$persistent.langcode}/#{name}"
|
translation_name = "#{$persistent.langcode}/#{name}"
|
||||||
if File.exist?("Graphics/Icons/#{translation_name}.png")
|
if File.exist?("Graphics/Icons/#{translation_name}.png")
|
||||||
@item_icon.bitmap = RPG::Cache.icon(translation_name)
|
@item_icon.bitmap = RPG::Cache.icon(translation_name)
|
||||||
else
|
else
|
||||||
@item_icon.bitmap = RPG::Cache.icon(name)
|
@item_icon.bitmap = RPG::Cache.icon(name)
|
||||||
end
|
end
|
||||||
@item_icon.zoom_x = 2.0
|
@item_icon.zoom_x = 2.0
|
||||||
@item_icon.zoom_y = 2.0
|
@item_icon.zoom_y = 2.0
|
||||||
|
|
||||||
|
|
@ -265,21 +267,22 @@ class Scene_Map
|
||||||
end
|
end
|
||||||
# Update fast travel
|
# Update fast travel
|
||||||
@fast_travel.update
|
@fast_travel.update
|
||||||
@window_settings.update
|
@window_settings.update
|
||||||
|
@window_debug.update
|
||||||
|
|
||||||
if Input.trigger?(Input::F8) && !$game_switches[123]
|
if Input.trigger?(Input::F8) && !$game_switches[123]
|
||||||
if Graphics.fullscreen == true
|
if Graphics.fullscreen == true
|
||||||
Graphics.fullscreen = false
|
Graphics.fullscreen = false
|
||||||
$console = false
|
$console = false
|
||||||
else
|
else
|
||||||
Graphics.fullscreen = true
|
Graphics.fullscreen = true
|
||||||
$console = true
|
$console = true
|
||||||
end
|
end
|
||||||
sleep(0.500)
|
sleep(0.500)
|
||||||
if @window_settings.visible
|
if @window_settings.visible
|
||||||
@window_settings.redraw_setting_index(2)
|
@window_settings.redraw_setting_index(2)
|
||||||
sleep(0.500)
|
sleep(0.500)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
# If showing message window
|
# If showing message window
|
||||||
if $game_temp.message_window_showing || @ed_message.visible || @doc_message.visible || @desktop_message.visible || @credits_message.visible
|
if $game_temp.message_window_showing || @ed_message.visible || @doc_message.visible || @desktop_message.visible || @credits_message.visible
|
||||||
|
|
@ -288,7 +291,7 @@ class Scene_Map
|
||||||
# Process menu opening
|
# Process menu opening
|
||||||
unless $game_system.map_interpreter.running? ||
|
unless $game_system.map_interpreter.running? ||
|
||||||
$game_system.menu_disabled ||
|
$game_system.menu_disabled ||
|
||||||
@fast_travel.visible || @window_settings.visible || $game_temp.menu_calling == true || $game_temp.item_menu_calling == true
|
@fast_travel.visible || @window_settings.visible || @window_debug.visible || $game_temp.menu_calling == true || $game_temp.item_menu_calling == true
|
||||||
if !@menu.visible && Input.trigger?(Input::MENU)
|
if !@menu.visible && Input.trigger?(Input::MENU)
|
||||||
$game_temp.menu_calling = true
|
$game_temp.menu_calling = true
|
||||||
$game_temp.menu_beep = true
|
$game_temp.menu_beep = true
|
||||||
|
|
@ -328,6 +331,8 @@ class Scene_Map
|
||||||
call_travel_menu
|
call_travel_menu
|
||||||
elsif $game_temp.window_settings_calling
|
elsif $game_temp.window_settings_calling
|
||||||
call_window_settings
|
call_window_settings
|
||||||
|
elsif $game_temp.window_debug_calling
|
||||||
|
call_window_debug
|
||||||
elsif $game_temp.save_calling
|
elsif $game_temp.save_calling
|
||||||
call_save
|
call_save
|
||||||
elsif $game_temp.debug_calling
|
elsif $game_temp.debug_calling
|
||||||
|
|
@ -427,6 +432,14 @@ class Scene_Map
|
||||||
# Open the menu
|
# Open the menu
|
||||||
@window_settings.open
|
@window_settings.open
|
||||||
end
|
end
|
||||||
|
def call_window_debug
|
||||||
|
# Clear menu call flag
|
||||||
|
$game_temp.window_debug_calling = false
|
||||||
|
# Straighten player position
|
||||||
|
$game_player.straighten
|
||||||
|
# Open the menu
|
||||||
|
@window_debug.open
|
||||||
|
end
|
||||||
#--------------------------------------------------------------------------
|
#--------------------------------------------------------------------------
|
||||||
# * Debug Call
|
# * Debug Call
|
||||||
#--------------------------------------------------------------------------
|
#--------------------------------------------------------------------------
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,9 @@
|
||||||
class Window_MainMenu < Window_Selectable
|
class Window_MainMenu < Window_Selectable
|
||||||
def initialize
|
def initialize
|
||||||
super(Graphics.width / 2 - 304, 16, 608, 64)
|
super(Graphics.width / 2 - 304, 16, 608, 64)
|
||||||
|
#kostil' ebanyy
|
||||||
|
@debug_menu = ::Window_TPtL.new
|
||||||
|
|
||||||
# Set up menu options
|
# Set up menu options
|
||||||
@commands = Array.new
|
@commands = Array.new
|
||||||
@commands << 'Fast Travel'
|
@commands << 'Fast Travel'
|
||||||
|
|
@ -150,11 +153,10 @@ class Window_MainMenu < Window_Selectable
|
||||||
$game_temp.window_settings_calling = true
|
$game_temp.window_settings_calling = true
|
||||||
@fade_out = true
|
@fade_out = true
|
||||||
when 3
|
when 3
|
||||||
@menu = ::Window_TPtL.new
|
$game_temp.window_debug_calling = true
|
||||||
@menu.open
|
@fade_out = true
|
||||||
@menu.dispose
|
end
|
||||||
end
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,11 @@
|
||||||
# The main menu window
|
# The main menu window
|
||||||
class Window_TPtL < Window_Selectable
|
class Window_TPtL < Window_Selectable
|
||||||
def initialize
|
def initialize
|
||||||
super(Graphics.width, 64, Graphics.height, 64)
|
super(16, 16, Graphics.width - 32, Graphics.height - 32)
|
||||||
@mapinfo = load_data("Data/MapInfos.rxdata")
|
@mapinfo = load_data("Data/MapInfos.rxdata")
|
||||||
|
|
||||||
@item_max = 262
|
@item_max = 262
|
||||||
@column_max = @item_max
|
@column_max = Graphics.width > 600 ? 4 : 2
|
||||||
|
|
||||||
# Make invisible by default
|
# Make invisible by default
|
||||||
self.visible = false
|
self.visible = false
|
||||||
|
|
@ -15,7 +15,7 @@ class Window_TPtL < Window_Selectable
|
||||||
@fade_out = false
|
@fade_out = false
|
||||||
|
|
||||||
# Render menu
|
# Render menu
|
||||||
self.contents = Bitmap.new(width - 32, 32)
|
self.contents = Bitmap.new(width - 32, @item_max * 32)
|
||||||
Language.register_text_sprite(self.class.name + "_contents", self.contents)
|
Language.register_text_sprite(self.class.name + "_contents", self.contents)
|
||||||
for i in 0...@item_max
|
for i in 0...@item_max
|
||||||
draw_item(i, normal_color)
|
draw_item(i, normal_color)
|
||||||
|
|
@ -38,11 +38,11 @@ class Window_TPtL < Window_Selectable
|
||||||
# Set color
|
# Set color
|
||||||
self.contents.font.color = color
|
self.contents.font.color = color
|
||||||
|
|
||||||
# Get width of text and cap
|
x = index % @column_max
|
||||||
w = self.width / @item_max
|
y = index / @column_max
|
||||||
|
|
||||||
# Update item
|
# Update item
|
||||||
rect = Rect.new(w * index, 0, w - 32, 32)
|
rect = Rect.new(self.width / @column_max * x, 32 * y, self.width / @column_max - 32, 32)
|
||||||
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
|
self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
|
||||||
self.contents.draw_text(rect, tr(@mapinfo&.[](index)&.name || "EMPTY"), 1)
|
self.contents.draw_text(rect, tr(@mapinfo&.[](index)&.name || "EMPTY"), 1)
|
||||||
end
|
end
|
||||||
|
|
@ -104,7 +104,6 @@ class Window_TPtL < Window_Selectable
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
# Cancel menu
|
# Cancel menu
|
||||||
if Input.trigger?(Input::CANCEL) ||
|
if Input.trigger?(Input::CANCEL) ||
|
||||||
Input.trigger?(Input::MENU) ||
|
Input.trigger?(Input::MENU) ||
|
||||||
|
|
@ -115,20 +114,20 @@ class Window_TPtL < Window_Selectable
|
||||||
@fade_out = true
|
@fade_out = true
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
end
|
|
||||||
|
|
||||||
# Select menu item
|
# Select menu item
|
||||||
if Input.trigger?(Input::ACTION)
|
if Input.trigger?(Input::ACTION)
|
||||||
self.active = false
|
self.active = false
|
||||||
self.opacity = 127
|
self.opacity = 127
|
||||||
$game_temp.player_transferring = true
|
$game_temp.player_transferring = true
|
||||||
$game_temp.player_new_map_id = @index
|
$game_temp.player_new_map_id = @index
|
||||||
$game_temp.player_new_x = 0
|
$game_temp.player_new_x = 0
|
||||||
$game_temp.player_new_y = 0
|
$game_temp.player_new_y = 0
|
||||||
$game_temp.player_new_direction = 0
|
$game_temp.player_new_direction = 0
|
||||||
Graphics.freeze
|
Graphics.freeze
|
||||||
$game_temp.transition_processing = true
|
$game_temp.transition_processing = true
|
||||||
$game_temp.transition_name = ""
|
$game_temp.transition_name = ""
|
||||||
@fade_out = true
|
@fade_out = true
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue