23.10.2010, 00:27
Guys, when a player spawns, it sets their pos, but if they die, it dont set there death pos (Hospital) it just reset them to the spawn pos.
Why does this not set the players pos when they die (same as question one) and it dont even send the message to all.
Why does this not set the players pos when they die (same as question one) and it dont even send the message to all.
pawn Код:
if(GetPlayerWantedLevel(playerid) == 2 && IsLaw[killerid] == 1)
{
new Str[256];
new Kname[256];
new PName[256];
new rand = random(sizeof(JailCellSpawns));
GetPlayerName(killerid,Kname,sizeof(Kname));
GetPlayerName(playerid,PName,sizeof(PName));
format(Str,66,"* %s has been jailed by %s.(2 mins)", PName, Kname);
SendClientMessage(playerid,red,"You have been jailed for 2 mins.");
SetPlayerPos(playerid, JailCellSpawns[rand][0], JailCellSpawns[rand][1], JailCellSpawns[rand][2]);
SendClientMessageToAll(red,Str);
jail[playerid] = 1;
tjail[playerid] = SetTimerEx("Unjail",120000,false,"i",playerid);
}


