13.03.2015, 21:38
Try this:
If it doesn't work show function "UnJail".
PHP код:
CMD:unjail(playerid, params[])
{
if(pInfo[playerid][pAdminLevel] >= 1)
{
if(sscanf(params, "u", params[0]))
return SendClientMessage(playerid, -1, "*"COL_WHITE" /unjail [playerid]");
if(!IsPlayerConnected(params[0]) && params[0] == INVALID_PLAYER_ID)
return SendClientMessage(playerid, -1, "*"COL_RED" Player is not connected.");
if(Jailed[params[0]] == 0)
return SendClientMessage(playerid, -1, "*"COL_RED" Player is not jailed.");
SetPlayerInterior(params[0], 0);
SetPlayerVirtualWorld(params[0], 0);
SpawnPlayer(params[0]);
SetPlayerHealth(params[0], 100);
KillTimer(JailTimer[params[0]]);
Jailed[params[0]] = 0;
}
return true;
}