/adminduty
#2

Alright, here's my version:
Код:
command(aduty, playerid, params[])
{
	if(Player[playerid][AdminLevel] >= 1)
	{
		if(isnull(params)) return SendClientMessage(playerid, WHITE, "Server: /aduty [on/off]");
		{
		    new string[256];
		    if(strmatch("on", params))
		    {
		        if(aDuty[playerid] == 0)
		        {
		            aDuty[playerid] = 1;
		            format(string, sizeof(string), "AdmMsg: Admin %s is now on Admin Duty.", RemoveUnderScore(playerid));
		            SendToAdmins(RED, string, 1);
		            SendToAdmins(RED, string, 0);
		            SetPlayerColor(playerid, ADUTY);
				}
				else return SendClientMessage(playerid, WHITE, "You are already on Admin Duty.");
			}
			else if(strmatch("off", params))
			{
			    if(aDuty[playerid] == 1)
			    {
			        aDuty[playerid] = 0;
			        format(string, sizeof(string), "AdmMsg: Admin %s in now off Admin Duty.", RemoveUnderScore(playerid));
			        SendToAdmins(RED, string, 1);
			        SendToAdmins(RED, string, 0);
			        SetPlayerColor(playerid, TRANSPARENT);
				}
				else return SendClientMessage(playerid, WHITE, "You are already off Admin Duty.");
			}
		}
	}
	else return SendClientMessage(playerid, GREY, AdminOnly);
	return 1;
}
Edit it to your likings if you want health, make a setplayerhealth, if you want a color change it from TRANSPARENT to "color here"

Simple
Reply


Messages In This Thread
/adminduty - QUICK HELP - by PabloDiCostanzo - 26.02.2013, 14:24
Re: /adminduty - by Mitchy - 26.02.2013, 19:54
Re: /adminduty - by seanny - 26.02.2013, 19:55
Re: /adminduty - by Oscii - 26.02.2013, 20:17
Re: /adminduty - by PabloDiCostanzo - 27.02.2013, 01:30
Re: /adminduty - by PabloDiCostanzo - 28.02.2013, 16:02
Respuesta: /adminduty - by Strier - 28.02.2013, 16:05
Re: /adminduty - by PabloDiCostanzo - 28.02.2013, 16:22
Re: /adminduty - by Denying - 28.02.2013, 16:30
Re: /adminduty - by Height - 28.02.2013, 16:38

Forum Jump:


Users browsing this thread: 1 Guest(s)