08.08.2017, 21:37
Maybe add this to the script?
Код:
stock FactionIDtoName(playerid) { new FactionName[144]; switch(PlayerInfo[playerid][pFacID]) { case 0: FactionName = "Police Departament"; // case 1: FactionName = "other names"; } return FactionName; }
Код:
CMD:fackick(playerid,params[]) { if(pInfo[playerid][AdminLevel] >= 3 || pInfo[playerid][pFacLeader] == 1) { new targetid; new string[128]; new sext[64]; if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, COLOR_RED, "/fackick [id]"); if(targetid != INVALID_PLAYER_ID) { if(pInfo[targetid][pFacID] == 1) { sext = "Police Departament"; } pInfo[targetid][pFacID] = 0; pInfo[targetid][pFacPRank] = 0; format(string,sizeof(string),"Ai fost dat afara din factiunea %s",FactionIDtoName(playerid)); SendClientMessage(playerid,0xFFFFFFAA,string); } } else { SendClientMessage(playerid, COLOR_RED, "Only certain levels of Administration have access to this command."); } return 1; }