mob
verb
Save()
var/savefile/F=new("Players/[src.ckey].Save")
Write(F)
src<<"Character Saved!"
mob
Write(savefile/F)
..()
F["mob"] << src
F["x"]<<x
F["y"]<<y
F["z"]<<z
F["dir"]<<dir
Read(savefile/F)
..()
F["mob"] >> src
F["x"]>>x
F["y"]>>y
F["z"]>>z
F["dir"]>>dir
src.loc=locate(src.x,src.y,src.z)
Problem description:
It makes you login twice for some reason.
I want a simple small save and read system like this, but one that works...
Please help!
This also means you would need to avoid saving any other reference to src, including those in objects contained by src. This can be avoided by not calling Read() and Write() directly, but saving and loading the object itself.
2. dir is saved automatically.
3. Loading x, y, and z individually won't do anything, and neither will setting loc to locate(x, y, z), since they would originally be equal.
The simple save-and-load, plus location-saving, without preventing icon-saving, and without any kind of future-proofing: