Project1
标题:
关于XP自动存档的问题
[打印本页]
作者:
y610407721
时间:
2012-5-22 21:14
标题:
关于XP自动存档的问题
本帖最后由 y610407721 于 2012-5-22 21:14 编辑
就是无需玩家手动存档,而是每隔几分钟,系统就自动存档,开始游戏的时候直接跳过标题,直接进入上次的地方. dsu_plus_rewardpost_czw
作者:
LOVE丶莫颜
时间:
2012-5-23 00:10
这种倒是没有,但是有一种“即时存档”不知道是不是你想要的效果呢?
就是那种你在退出游戏时,不用手动保存,系统会自动保存的。
作者:
大东
时间:
2012-5-23 06:11
可以通过并行事件写入存档!找一下写入存档的那句脚本,应该是在if当按键c按下时,播放se,写入存档(几号)
进入游戏可以在标题前加个分歧,如果检测到这个存档的存在,直接读取这个存档,如果没有,正常使用标题!(手机回的,没办法写范例给楼主,而且也只记得要怎么做!具体脚本句还请楼主找一下)
作者:
hys111111
时间:
2012-5-23 21:29
本帖最后由 hys111111 于 2012-5-23 21:45 编辑
AUTO_SAVE_SWITCH = 3 #当3号开关打开时,自动存档无效
#为了防止卡死,设定每隔10秒自动存档
class Scene_Map
alias hys_auto_save update
def update
sec = Graphics.frame_count / Graphics.frame_rate % 60
if !$game_switches[AUTO_SAVE_SWITCH] and sec % 10 == 0
Scene_Save.new.on_decision("AutoSave.rxdata")
end
hys_auto_save
end
end
class Scene_Title
alias command_next update
def update
if FileTest.exist?("AutoSave.rxdata")
Scene_Load.new.on_decision("AutoSave.rxdata")
else
command_next
end
end
end
class Scene_Save < Scene_File
def on_decision(filename)
# 演奏存档 SE
#$game_system.se_play($data_system.save_se)
# 写入存档数据
file = File.open(filename, "wb")
write_save_data(file)
file.close
# 如果被事件调用
#if $game_temp.save_calling
# 清除存档调用标志
$game_temp.save_calling = false
# 切换到地图画面
$scene = Scene_Map.new
return
#end
# 切换到菜单画面
#$scene = Scene_Menu.new(4)
end
end
复制代码
原脚本有些问题,现已修复
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1