Help Please - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help Please (
/showthread.php?tid=291457)
Help Please -
Buzzbomb - 19.10.2011
How would i go about loading Player Position i got it to save but having the most hardest time getting it load it..
pawn Код:
if(PlayerInfo[playerid][pLocX] == 0.0 && PlayerInfo[playerid][pLocY] == 0.0)
{
SetPlayerPos(playerid, PlayerInfo[playerid][pLocX], PlayerInfo[playerid][pLocY], PlayerInfo[playerid][pLocZ]); // Loads Spawning but NOT working
SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pLocW]);
SetPlayerInterior(playerid, PlayerInfo[playerid][pLocI]);
TogglePlayerSpectating(playerid, false);
}
else
{
SetPlayerPos(playerid, -299.8857, 1015.5681, 19.5938); // For if Player Cords are 0 Spawns them on Ground
TogglePlayerSpectating(playerid, false);
}
Dont work ...
Re: Help Please -
=WoR=Varth - 20.10.2011
Where you put that code?
Re: Help Please -
GrimR - 20.10.2011
Dude put ur conditional code the other way around.
Re: Help Please -
SuperViper - 20.10.2011
pawn Код:
if(PlayerInfo[playerid][pLocX] != 0.0 && PlayerInfo[playerid][pLocY] != 0.0)
{
SetPlayerPos(playerid, PlayerInfo[playerid][pLocX], PlayerInfo[playerid][pLocY], PlayerInfo[playerid][pLocZ]); // Loads Spawning but NOT working
SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pLocW]);
SetPlayerInterior(playerid, PlayerInfo[playerid][pLocI]);
TogglePlayerSpectating(playerid, false);
}
else
{
SetPlayerPos(playerid, -299.8857, 1015.5681, 19.5938); // For if Player Cords are 0 Spawns them on Ground
TogglePlayerSpectating(playerid, false);
}
Re: Help Please -
Buzzbomb - 21.10.2011
Okay Ive put the code on player Request Class and even on player spawn and I switched them around it still never called on there last position it spawned them at the SetPlayerPos(playerid, -299.8857, 1015.5681, 19.593

;
I even tried making a new Function and used SetTimerEx and Still.. nothing
Re: Help Please -
=WoR=Varth - 21.10.2011
Have you tried SuperViper code?
To make sure, debug PlayerInfo[playerid][pLocX] and PlayerInfo[playerid][pLocY].