- 0
Ajutor /jail
-
Similar Content
-
Recently Browsing 0 members
- No registered users viewing this page.
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.
Question
alinutz_boy32
Cum fac cand esti inchis in puscarie sa nu poti folosi nici`o teleportare/comanda!
Comanda este aceasta!
[pawn]CMD:jail(playerid,params[])
{
if(IsPlayerAdmin(playerid) || PlayerInfo[playerid][Level] <= 3)
{
new jtime, tmp3[50], player1, string[128];
//------------------------------------------------------------------
if(sscanf(params, "uIS()[50]", player1, jtime, tmp3)) return
SendClientMessage(playerid, LIGHTBLUE2, "Usage: /jail [PlayerID] [Minutes] [Reason]") &&
SendClientMessage(playerid, orange, "Function: Will Jailed the specified player");
//------------------------------------------------------------------
if(PlayerInfo[player1][Jailed] == 0)
{
if(jtime == 0) jtime = 9999;
//----------------------------------------------------------
PlayerInfo[player1][JailTime] = jtime*1000*60;
SetTimerEx("JailPlayer", 5000, false, "i", player1);
SetTimerEx("Jail1", 1000, false, "i", player1);
PlayerInfo[player1][Jailed] = 1;
SetPVarInt(player1, "Jailed", 1);
//----------------------------------------------------------
if(jtime == 9999)
{
if(!strlen(tmp3))
{
format(string, 128,"Administrator %s has Jailed %s",GetName(playerid), GetName(player1));
}
else format(string, 128,"Administrator %s has Jailed %s (Reason: %s)",GetName(playerid), GetName(player1), tmp3);
}
else
{
if(!strlen(tmp3))
{
format(string, 128,"Administrator %s has Jailed %s for %d Minutes",GetName(playerid), GetName(player1), jtime);
}
else format(string, 128,"Administrator %s has Jailed %s for %d Minutes (Reason: %s)",GetName(playerid), GetName(player1), jtime,tmp3);
}
return SendClientMessageToAll(blue,string);
}
else return SendClientMessage(playerid, red, "ERROR: Player is already in jail");
}
else return SendClientMessage(playerid,red,"ERROR: You must be Admin lvl 4 to use this command");
}
[/pawn]
14 answers to this question
Recommended Posts