22.03.2013, 05:36
How to make a command /aduty that put admin on duty and how to make a /v command with model name or part of model name.
enum ainfo { onduty }
ainfo[playerid][onduty] = 0;
ainfo[playerid][onduty] = 0;
CMD:onduty(playerid,params[]) { if.........//here your level check command{ if(aInfo[playerid][OnDuty] == 0) { aInfo[playerid][OnDuty] = 1; return SendClientMessage(playerid,0x00FFAA,"|- You are now in \"Duty Mode\" -|"); } else { aInfo[playerid][OnDuty] = 0; return SendClientMessage(playerid,0x00FFAA,"|- You are now in \"Playing Mode\"-|"); } } return SendClientMessage(playerid, red, "You are not high enough to use this command"); }
new bool:aduty[MAX_PLAYERS]
Why an enum? Ofcourse it works, but I suggest you using something like
pawn Код:
|