02-01-2007, 11:12 PM
I have to respond .... .... there is a much quicker way to do this ...
That will save the whole player. No need to save each member individually.
Same with items, npcs, shops, spells, etc. Can load them pretty much the same ...
Basically the same way maps are loaded and saved. Dont have to really worry about the extra stuff attached like Bytecount, etc, as those should be cleared on ClearPlayer(Index).
And .. it's faster doing a save/load on the whole structure instead of individual members. The compiler does some weird optimizations in the background.
Code:
Put #nFileNum, , Player(index)
That will save the whole player. No need to save each member individually.

Same with items, npcs, shops, spells, etc. Can load them pretty much the same ...
Code:
Get #nFileNum, , Player(index)
Basically the same way maps are loaded and saved. Dont have to really worry about the extra stuff attached like Bytecount, etc, as those should be cleared on ClearPlayer(Index).

And .. it's faster doing a save/load on the whole structure instead of individual members. The compiler does some weird optimizations in the background.