02.09.2013, 23:37
pawn Код:
new
Float: deathX[MAX_PLAYERS],
Float: deathY[MAX_PLAYERS],
Float: deathZ[MAX_PLAYERS],
bool: playerDied[MAX_PLAYERS];
public OnPlayerSpawn(playerid)
{
if(playerDied[playerid]) {
SetPlayerPos(playerid, deathX[playerid], deathY[playerid], deathZ[playerid]);
playerDied[playerid] = false;
return 1;
}
return 1;
}
public OnPlayerDeath(playerid, killerid, reason)
{
GetPlayerPos(playerid, deathX[playerid], deathY[playerid], deathZ[playerid]);
playerDied[playerid] = true;
return 1;
}