#==============================================================================
# ■ Game_Interpreter_Self
#------------------------------------------------------------------------------
# 独立公共事件执行器
#==============================================================================
=begin
独立公共事件执行器用于随时执行公共事件,不受公共事件调用地方的限制。
□使用方法:
1。将脚本插入main前。
2。在需要使用公共事件的地方
插入、
GIS.new(公共事件ID)
□可能的冲突:无
已经被改过兼容VA了。
原制作者为九夜神尊。
=end
class GIS < Game_Interpreter
def initialize(com_id)
@com_id = com_id
common_event = $data_common_events[@com_id]
setup(common_event.list)
update
clear
end
def command_117
if $data_common_events[@params[0]]
child = Game_Interpreter_Self.new(@params[0])
child.run
end
end
end
class Window_MenuCommand < Window_Command
alias m5_20150706_add_save_command add_save_command
def add_save_command
m5_20150706_add_save_command
add_command("任务", :save1, true)
add_command("技能强化", :save2, true)
end
def add_game_end_command
add_command("系统", :game_end)
end
end
class Scene_Menu < Scene_MenuBase
alias ccw_zabing create_command_window
def create_command_window
ccw_zabing
@command_window.set_handler(:save1, method(:command_save1))
@command_window.set_handler(:save2, method(:command_save2))
end
def command_save1
SceneManager.call(Scene_Task)
end
def command_save2
SceneManager.call(Scene_SUP)
end
end
class Scene_End < Scene_MenuBase
alias ccw_zabing create_command_window
def create_command_window
ccw_zabing
@command_window.set_handler(:to_load, method(:command_to_load))
end
def command_to_load
close_command_window
fadeout_all
SceneManager.call(Scene_Load)
end
end
class Window_GameEnd < Window_Command
alias mcl_zabing make_command_list
def make_command_list
mcl_zabing
add_command("读档", :to_load)
end
end