Saving and loading the players pos?
#2

pawn Код:
enum _PINFO
{      Float:pLastX,
    Float:pLastY,
    Float:pLastZ
   
}
new PVar[MAX_PLAYERS][_PINFO];
Under OnPlayerDisconnect add
pawn Код:
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
plastX = x;
plastY = y;
plastZ = z;
and save them to the players file.


under OnPlayerSpawn
pawn Код:
//some sort of check if the player has been on the server before

SetPlayerPos(playerid,plastX,plastY,plastZ);
hope that helped
Reply


Messages In This Thread
Saving and loading the players pos? - by DjAdy - 14.06.2011, 22:02
Re: Saving and loading the players pos? - by xalith - 14.06.2011, 22:14

Forum Jump:


Users browsing this thread: 1 Guest(s)