Posts: 1,506
Threads: 13
Joined: Jun 2015
Quote:
Originally Posted by jlalt
i'm not sure but this should work .-.
PHP код:
CMD:unban(playerid,params[]) {
if(IsPlayerAdmin(playerid)) {
if(isnull(params)) return SendClientMessage(playerid, red, "USAGE: /unban [name]");
if(udb_Exists(params)) {
if(0 == dUserINT(params).("banned")) return SendClientMessage(playerid,red,"ERROR: Player is already unbanned");
dUserSetINT(params).("banned",0);
new string[128];
PlayerPlaySound(playerid,1057,0.0,0.0,0.0);
format(string,sizeof(string),"You have Successfully unbanned {FF0000}%s",params);
return SendClientMessage(playerid, 0x00FFFFAA, string);
} else return SendClientMessage(playerid, 0xFF0000AA, "ERROR: File doesnt exist, player isnt registered");
} else return SendClientMessage(playerid, 0xFF0000AA, "ERROR: You need to be RCON to use this command");
}
|
Works, Approved. Tested it with my GM and it works absolutely fine.