PDA

View Full Version : Saving skins


HDFord
02/04/2012, 12:42 PM
I want people to spawn at the same location as they were on when they disconnected, that's no problem. But when i'm saving the skin on "OnPlayerDisconnect" i use "GetPlayerSkin".

But how can i give the skin the player had before disconnecting back when player spawns with "SetPlayerSkin" or something else if possible.

ReneG
02/04/2012, 12:52 PM
Under OnPlayerDisconnect you would use
new skin = GetPlayerSkin(playerid);
Then write it as so in their .ini file. If you already have their positions saved.
Add an if under OnPlayerSpawn if their x variable is equal to 0 then spawn them at the noob spawn and give them the newb skin. Else, they get the skin they last had.