27.01.2015, 16:43
How to create Jail and unJail command ?
new Jailed[MAX_PLAYERS];
CMD:jail(playerid, params[])
{
if(!IsPlayerAdmin(playerid)) return 0;
new id;
if(sscanf(params, "u", id)) return SendClientMessage(playerid, -1, "/jail [id]");
if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "Invalid player id");
SendClientMessage(id, "You've been jailed.");
SetPlayerInterior(id, 3);
SetPlayerPos(id, 197.6661, 173.8179, 1003.0234);
Jailed[id]=1;
return 1;
}