[HELP] Spawn Point Save
#1

How can i save my spawn point?
like i spawn on the place i logged off.
To me you either spawn on newb spawn or your familie house. How can i remove it? or add a place saver?

THNX I NEED IT
Reply
#2

well you need to try something like

Код:
Public OnPlayerDissconect
{
new float:LogX,float:LogY,float:LogZ;
GetPlayerPos(playerid, LogX,LogY,LogZ);
and use a varibale to save this cords for example
PlayerInfo[playerid][logpositionX] = LogX;
PlayerInfo[playerid][logpositionX] = Log,Y;
PlayerInfo[playerid][logpositionX] = LogZ;
}
and then on player spawn you make a call back 

public onplayerspawn
{
if(!PlayerInfo[playerid][logposition]= 0)
{
  new LogX = PlayerInfo[playerid][logpositionX];
  new LogY = PlayerInfo[playerid][logpositionY];
  new LogZ = PlayerInfo[playerid][logpositionZ];
  SetPlayerPost(playerid,LogX,LogY,LogZ);
}
}
thats an example and wont work 100% just trying to help you understand
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)