Project1
标题:
如何在标题画面时多一个选项?
[打印本页]
作者:
黑色的笔
时间:
2012-1-26 12:48
标题:
如何在标题画面时多一个选项?
我想在"开始游戏""读取""退出"那一块再加一个"小游戏",脚本我会看不会改,请问谁能帮忙告诉我怎么弄?
小游戏的地图我画好了,只要一按选项就奔到那个地图就OK了.
(顺便问管理员:这样算伸手么?不然怎么样才不算?) dsu_plus_rewardpost_czw
作者:
亿万星辰
时间:
2012-1-26 12:57
本帖最后由 亿万星辰 于 2012-1-26 12:57 编辑
在本版搜索“标题 选项”即可找到若干类似问题~
作者:
腐琴琴
时间:
2012-1-26 13:07
本帖最后由 腐琴琴 于 2012-1-26 13:10 编辑
特殊开头.rar
(414.2 KB, 下载次数: 12)
2012-1-26 13:10 上传
点击文件名下载附件
在Scene_Title这里可以加选项
s1 = "新游戏"
s2 = "继续"
s3 = "退出"
@command_window = Window_Command.new(192, [s1, s2, s3])
复制代码
s1 = "新游戏"
s2 = "继续"
s3 = "额外"
s4 = "退出"
@command_window = Window_Command.new(192, [s1, s2, s3,s4])
复制代码
还有这里改一下:
if Input.trigger?(Input::C)
# 命令窗口的光标位置的分支
case @command_window.index
when 0 # 新游戏
command_new_game
when 1 # 继续
command_continue
when 2 # 退出
command_shutdown
复制代码
when 0 # 新游戏
command_new_game
when 1 # 继续
command_continue
when 2 # 额外
command_another_game
when 3 # 退出
command_shutdown
复制代码
然后把新游戏的东西复制一份
def command_new_game
# 演奏确定 SE
$game_system.se_play($data_system.decision_se)
# 停止 BGM
Audio.bgm_stop
# 重置测量游戏时间用的画面计数器
Graphics.frame_count = 0
# 生成各种游戏对像
$game_temp = Game_Temp.new
$game_system = Game_System.new
$game_switches = Game_Switches.new
$game_variables = Game_Variables.new
$game_self_switches = Game_SelfSwitches.new
$game_screen = Game_Screen.new
$game_actors = Game_Actors.new
$game_party = Game_Party.new
$game_troop = Game_Troop.new
$game_map = Game_Map.new
$game_player = Game_Player.new
# 设置初期同伴位置
$game_party.setup_starting_members
# 设置初期位置的地图
$game_map.setup($data_system.start_map_id)
# 主角向初期位置移动
$game_player.moveto($data_system.start_x, $data_system.start_y)
# 刷新主角
$game_player.refresh
# 执行地图设置的 BGM 与 BGS 的自动切换
$game_map.autoplay
# 刷新地图 (执行并行事件)
$game_map.update
# 切换地图画面
$scene = Scene_Map.new
end
复制代码
然后在
start_map_id
复制代码
中的start_map_id改成一个数字,然后就在该数字编号的地图做事件……
def command_new_game
# 演奏确定 SE
$game_system.se_play($data_system.decision_se)
# 停止 BGM
Audio.bgm_stop
# 重置测量游戏时间用的画面计数器
Graphics.frame_count = 0
# 生成各种游戏对像
$game_temp = Game_Temp.new
$game_system = Game_System.new
$game_switches = Game_Switches.new
$game_variables = Game_Variables.new
$game_self_switches = Game_SelfSwitches.new
$game_screen = Game_Screen.new
$game_actors = Game_Actors.new
$game_party = Game_Party.new
$game_troop = Game_Troop.new
$game_map = Game_Map.new
$game_player = Game_Player.new
# 设置初期同伴位置
$game_party.setup_starting_members
# 设置初期位置的地图
$game_map.setup($data_system.start_map_id)
# 主角向初期位置移动
$game_player.moveto($data_system.start_x, $data_system.start_y)
# 刷新主角
$game_player.refresh
# 执行地图设置的 BGM 与 BGS 的自动切换
$game_map.autoplay
# 刷新地图 (执行并行事件)
$game_map.update
# 切换地图画面
$scene = Scene_Map.new
end
#====================================================================
def command_another_game
# 演奏确定 SE
$game_system.se_play($data_system.decision_se)
# 停止 BGM
Audio.bgm_stop
# 重置测量游戏时间用的画面计数器
Graphics.frame_count = 0
# 生成各种游戏对像
$game_temp = Game_Temp.new
$game_system = Game_System.new
$game_switches = Game_Switches.new
$game_variables = Game_Variables.new
$game_self_switches = Game_SelfSwitches.new
$game_screen = Game_Screen.new
$game_actors = Game_Actors.new
$game_party = Game_Party.new
$game_troop = Game_Troop.new
$game_map = Game_Map.new
$game_player = Game_Player.new
# 设置初期同伴位置
$game_party.setup_starting_members
# 设置初期位置的地图
$game_map.setup(2)
# 主角向初期位置移动
$game_player.moveto($data_system.start_x, $data_system.start_y)
# 刷新主角
$game_player.refresh
# 执行地图设置的 BGM 与 BGS 的自动切换
$game_map.autoplay
# 刷新地图 (执行并行事件)
$game_map.update
# 切换地图画面
$scene = Scene_Map.new
end
复制代码
������
作者:
黑色的笔
时间:
2012-1-26 13:41
腐琴琴 发表于 2012-1-26 13:07
在Scene_Title这里可以加选项还有这里改一下:然后把新游戏的东西复制一份然后在中的start_map_id改成一个 ...
啊哈,学会了,谢谢!
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1