20.02.2013, 18:53
Hey guys, I was on my server with my friend testing out the jail function. I told him to jail me, then kick me. I came back to the server, and it says that I have been automatically released from jail. But whats weird, the timer should stop counting after I leave the server. Can you please help? Heres the auto un jail function:
Is it possible to kill the timer after the person disconnects, and comes back?
Please help
Код:
public Unjail(playerid)
{
if(Jailed[playerid] == 0)
return 1;
new playerName[24], String[128];
GetPlayerName(playerid, playerName, sizeof(playerName));
format(String, sizeof(String), "%s {FFFFFF}has been automatically released from Admin jail.", playerName);
SendClientMessageToAll(0x009DFFFF, String);
Jailed[playerid] = 0;
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid, 0);
SpawnPlayer(playerid);
SetPlayerHealth(playerid, 100);
KillTimer(JailTimer[playerid]);
return 1;
}
Please help

