mob/proc/Save()
src.xx = src.x
src.yy = src.y
src.zz = src.z
src.V = src.verbs
var/savefile/F = file("Chronicles of...\ Saves \ [src.ckey].gamsav")
F << src.party
Write(F)
mob/proc/Auto_Save()
src.Save()
spawn(1200)
src.Auto_Save()
mob/proc/Load()
if(fexists("Chronicles of...\ Saves \ [src.ckey].gamsav"))
var/savefile/F =file("Chronicles of...\ Saves \ [src.ckey].gamsav")
Read(F)
F >> src.party
var/src.party/S
src.loc = locate(src.xx,src.yy,src.zz)
for(var/mob/M in src.party)
M.loc = src.loc
for(var/stuff in src.V)
src.verbs += stuff
else
src<<"You have no savefile."
Login Code
mob/Login()
src<< sound('145838_LostGiftTheme2_full.ogg',1)
alert("Welcome.","","New Game","Load Game")
if("New Game")
src.loc = locate(2,2,1)
src.Save()
src.Auto_Save()
src<<"Your game will always save. It will auto-save when you log out."
if("Load Game")
src.Load()
src.Auto_Save()
Problem description:
And a savefile is .sav, not .gamsav.