SA-MP Forums Archive
Now how can i spawn the player - 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: Now how can i spawn the player (/showthread.php?tid=560562)



Now how can i spawn the player - S4MSUNG - 29.01.2015

I recently got this codes from my scripter friend, Now whats the code for spawning the player using that position, Virtual world, interior and angle gather below

pawn Код:
PlayerInfo[playerid][pInt] = GetPlayerInterior(playerid);
                PlayerInfo[playerid][pVW] = GetPlayerVirtualWorld(playerid);
                GetPlayerPos(playerid, PlayerInfo[playerid][pPos_x], PlayerInfo[playerid][pPos_y], PlayerInfo[playerid][pPos_z]);
                GetPlayerFacingAngle(playerid, PlayerInfo[playerid][pPos_r]);



Re: Now how can i spawn the player - PaulDinam - 29.01.2015

And your question is?


Re: Now how can i spawn the player - HydraHumza - 29.01.2015

what u mean? i can't understand what are you trying to say?


Re: Now how can i spawn the player - RedFusion - 29.01.2015

Simple:
pawn Код:
SetPlayerInterior(playerid, PlayerInfo[playerid][pInt]);
SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pVW]);
SetPlayerPos(playerid, PlayerInfo[playerid][pPos_x], PlayerInfo[playerid][pPos_y], PlayerInfo[playerid][pPos_z]);
SetPlayerFacingAngle(playerid, PlayerInfo[playerid][pPos_r]);



Re: Now how can i spawn the player - JaydenJason - 29.01.2015

Don't you think you should use enums instead of playerinfo[playerid][pint] = Getplayerinterior etc


Re: Now how can i spawn the player - S4MSUNG - 29.01.2015

Quote:
Originally Posted by RedFusion
Посмотреть сообщение
Simple:
pawn Код:
SetPlayerInterior(playerid, PlayerInfo[playerid][pInt]);
SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pVW]);
SetPlayerPos(playerid, PlayerInfo[playerid][pPos_x], PlayerInfo[playerid][pPos_y], PlayerInfo[playerid][pPos_z]);
SetPlayerFacingAngle(playerid, PlayerInfo[playerid][pPos_r]);
THANKS BRO,