10.06.2018, 19:44
Hi!
I have been looking for a long time how to spawn a player in prison when he was killed by a policeman, but I can not do it, here is my code:
in OnPlayerDeath :
if(GetPlayerWantedLevel(playerid) >= 1)
{
if(gTeam[killerid] == TEAM_POLICIER)
{
PlayerIsInJail[playerid] = 1;
}
}
in OnPlayerSpawn :
if(PlayerIsInJail[playerid] == 1)
{
SetPlayerPos(playerid, 197.39999389648, 173.39999389648, 1003);
SetPlayerFacingAngle(playerid, 0);
SetPlayerInterior(playerid, 3);
SetCameraBehindPlayer(playerid);
return 1;
}
Thanks in advance to help me, thanks !
I have been looking for a long time how to spawn a player in prison when he was killed by a policeman, but I can not do it, here is my code:
in OnPlayerDeath :
if(GetPlayerWantedLevel(playerid) >= 1)
{
if(gTeam[killerid] == TEAM_POLICIER)
{
PlayerIsInJail[playerid] = 1;
}
}
in OnPlayerSpawn :
if(PlayerIsInJail[playerid] == 1)
{
SetPlayerPos(playerid, 197.39999389648, 173.39999389648, 1003);
SetPlayerFacingAngle(playerid, 0);
SetPlayerInterior(playerid, 3);
SetCameraBehindPlayer(playerid);
return 1;
}
Thanks in advance to help me, thanks !