world
mob=/mob/player
New()
..()
spawn()Rebooter()
proc
Rebooter()
sleep(54000)
world << "<b><font color = purple>World Rebooting in 30 minutes.!"
sleep(6000)
world << "<b><font color = purple>World Rebooting in 20 minutes."
sleep(6000)
world << "<b><font color = purple>World Rebooting in 10 minutes. Wrap it up!"
sleep(6000)
if(eventon)
world << "<b><font color = purple><font size=3>World Rebooting in 5 more minutes due to event. Stay put!"
sleep(3000)
if(eventon)
world << "<b><font color = purple><font size=3>World Rebooting in 5 more minutes due to event. LAST CALL!"
sleep(3000)
world << "<b><font color = purple><font size=3>World Rebooting in 30 seconds. Stay put!"
sleep(300)
for(var/mob/m in world)
if(m.client)
m.saveproc()
NameSave()
AllySave()
OrgSave()
sleep(30)
world.Reboot()
mob
proc
saveproc()
if(src.cansave)
if(src.contents.len>=1)
var/keys=src.key
var/savefile/save
save = new("playerswwa/[keys]/[src.name]")
save["mob"] << src
save["x"] << src.x
save["y"] << src.y
save["z"] << src.z
mob
proc
count_chars()
var/totalSaves=0
var/keys=src.key
var/list/saveFiles=flist("playerswwa/[keys]/")
for(var/v in saveFiles)
totalSaves++
return totalSaves
get_char_list()
var/keys=src.key
var/list/saveFiles=flist("playerswwa/[keys]/")
var/list/save_display=list()
for(var/v in saveFiles)
save_display+=v//ascii_string2text("[v]")
return save_display
load()
if(!src)
return
var/keys=src.key
var/list/saveFiles=src.get_char_list()
if(!src.count_chars())
return
var/choice=input("Welcome to (game name)! Who do you want to load?\n\n\
\n\nSavefiles Used: [src.count_chars()]/3","Login")as null|anything in saveFiles
if(fexists("playerswwa/[keys]/[choice]"))
var/savefile/load
load = new ("playerswwa/[keys]/[choice]")
load["mob"] >> usr
load["x"] >> usr.x
load["y"] >> usr.y
load["z"] >> usr.z
//the rest of the load proc
Problem description:
Some players can't load their savefile from time to time as if it's corrupt. This problem occurs randomly so it's hard to duplicate so it's hard to find a solution. This is all the important save codes, is there a reason to why people randomly can't load their character?