03.06.2010, 06:37
SEARCH
But yea for the first question:
First add a variable in your Player Info enum (if you use one)
If you use DCMD
DCMD version:
But yea for the first question:
First add a variable in your Player Info enum (if you use one)
Код:
if(!strcmp(cmdtext,"/onduty",true,7)==0) { if(!PlayerInfo[playerid][AdminLevel>0) return SendClientMessage(playerid,0xffffffaa,"You are not an Admin"); //use your varaibles here PlayerInfo[playerid][onduty]=1; //here too return SendCleintMessage(playerid,0xffffffaa,"You are now on Admin Duty."); //You can't remove one guys PlayerMarker from the mini-map afaik }
DCMD version:
Код:
dcmd_onduty(playerid,params[]) { if(!PlayerInfo[playerid][AdminLevel>0) return SendClientMessage(playerid,0xffffffaa,"You are not an Admin"); //use your varaibles here PlayerInfo[playerid][onduty]=1; //here too return SendCleintMessage(playerid,0xffffffaa,"You are now on Admin Duty."); //Then under OnPlayerCommandTExt function dcmd(onduty,6,cmdtext); }