ID:2031929
 
So I don't even know where to begin with this really. I need to save and load two mobs controlled by a user at a time from a save file. The way the game is setup the user controls two heroes that just follows the lead (whichever the user has their key attached to) and the user has a verb that swaps between the active and inactive one. But I need both the mobs to be saved within a file and loaded up.
If you know how to save and load datums in general, it should be fairly straightforward.

To save a datum to a savefile:
var thing_to_save = // this could be src or really anything else
var savefile/s = new ("folder/filename.extension")
s << thing_to_save

To load a datum from a savefile:
var loaded_thing
var savefile/s = new ("folder/filename.extension")
s >> loaded_thing

Swapping between mobs is slightly tricky.
// so you have two mobs, call them a and b
// (in your case, one of them might just be src)
var mob/a = ...
var mob/b = ...

// if we're currently controlling a and want to switch to b,
// these are a few ways to do it:
b.key = a.key

b.client = a.client

a.client.mob = b

When any of those 3 statements are executed, the BYOND engine will call a.Logout() and b.Login(), so make sure that you don't have any titlescreen stuff in either of those. That stuff should go under a different type of mob entirely. Also, don't delete either mob on logout, of course. If you want to do things when a client connects to or disconnects from the game, do it in client/New() (after . = ..()) and client/Del() (before ..()).
I have the swapping mechanic already in place and it works wonders. Ill try what you suggested with the load and saves right now.
Will have to tweak all my login, logout, new, del procedures to get this to work right. Since now everytime i swap to the inactive hero it messes up. This is gonna be awhile.