mob
proc
SaveGame()
set name = "Save"
if(CanSave)
if(SaveSlot!=0)
if(fexists("Players/[uppertext(copytext(key,1,2))]/[key]/Slot [SaveSlot](1).sav"))fdel("Players/[uppertext(copytext(key,1,2))]/[key]/Slot [SaveSlot](1).sav")
var/savefile/F=new("Players/[uppertext(copytext(key,1,2))]/[key]/Slot [SaveSlot](1).sav")
V=verbs
lastx=x
lasty=y
lastz=z
id=ID
Write(F)
spawn(10) usr << "<font color=White><b>Your game has been saved!"
else src<<"[ERROR]Bug has been occured. Please relog."
Load()
if("Slot 1")
if(fexists("Saves/[src.client.ckey]/Slot1.sav"))
usr.save_file_1 = 1
usr.LoadFile()
else
alert("You don't have a character in this slot!")
sleep(5)
return
if("Slot 2")
if(fexists("Saves/[src.client.ckey]/Slot2.sav"))
usr.save_file_2 = 1
usr.LoadFile()
else
alert("You don't have a character in this slot!")
sleep(5)
return
if("Slot 3")
if(fexists("Saves/[src.client.ckey]/Slot3.sav"))
usr.save_file_3 = 1
usr.LoadFile()
else
alert("You don't have a character in this slot!")
sleep(5)
return
Problem description:
first problem is when i load i get this:
runtime error: Cannot read null.ckey
proc name: Load (/mob/proc/Load)
source file: Creation.dm,117
usr: Guest (/mob/Guest)
src: Guest (/mob/Guest)
call stack:
Guest (/mob/Guest): Load()
Load (11,13,1) (/turf/Load): Click(Load (11,13,1) (/turf/Load), "mapwindow.map", "icon-x=21;icon-y=8;left=1")
And take me to selection screen
second problem is saving wont work....
and last problem is the character wont move i added mob/move() but nothing
bump help anyone