client
Del()
..()
mob.Save()
mob
player
icon = 'player.dmi'
density = 1
Login()
..()
world<<"[src.name], just logged into, [world.name]!"
creating
Login()
if(fexists("players/[copytext(src.ckey,1,2)]/[src.ckey].sav"))
switch(alert(src,"WARNING: You already have a savefile, continue anyhow?","[world.name]","Yes","No"))
if("Yes")
spawn(1)
src.Create()
else
spawn(1)
src.Load()
else
spawn(1)
src.Create()
proc
Load()
var
savefile
F=new("players/[copytext(src.ckey,1,2)]/[src.ckey].sav")
if(fexists(F))
spawn(1)
src.Read(F)
Create()
var
mob
player
P=new
n
while(!n)
n=input("What is your name?","[world.name]","[src.key]") as text|null
P.name=html_encode(n)
src.client.mob=P
del(src)
Read(savefile/F)//define argument savefile/F
..()
var
last_x
last_y
last_z
F["MOB"]>>src
F["last_x"]>>last_x
F["last_y"]>>last_y
F["last_z"]>>last_z
src.loc=locate(last_x,last_y,last_z)
Write(savefile/F)
..()
F["MOB"]<<src
F["last_x"]<<src.x
F["last_y"]<<src.y
F["last_z"]<<src.z
verb
Save()
if(istype(usr,/mob/player/))
var
savefile
F=new("players/[copytext(usr.ckey,1,2)]/[usr.ckey].sav")
usr.Write(F)
thats my saving system which my brother helped me come up with and its not showing the map when i logback in anytips on why and how i can fix?
ID:147676
![]() Feb 1 2004, 10:47 am
|
|
>client Put the mob.Save() bit before the ..(), or the client will be eleted before it's saved. Login() Put a ..() in there somewhere. Maybe at the end? |
Login()
//whatever
..()