02.12.2009, 23:16
Okay.
pawn Код:
//top of script after #include <a_samp> and before main()
new HasDied[MAX_PLAYERS];
//This is to make sure they have died and not just entered the server
public OnPlayerDeath(playerid, reason)
{
HasDied[playerid] = 1;
return 1;
}
public OnPlayerSpawn(playerid)
{
if(HasDied[playerid] == 1)
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsMedic[i] == 1) //your variable to check if the player is a medic
{
SetPlayerCheckPoint(i, X, Y, Z, 5);
}
}
}
return 1;
}