17.08.2012, 10:39
ok i have these 2 commands
can you merge them into one cmd like /aduty and then again to go off duty plox
pawn Код:
CMD:aduty(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 2)
{
new name[24],ostring[124];
GetPlayerName(playerid,name,sizeof(name));
format(ostring,sizeof(ostring),"Administrator %s is now on duty (/report For Assistance).",name);
SendClientMessageToAll(-1,ostring);
SetPlayerHealth(playerid, 100000);
SetPlayerArmour(playerid, 100000);
SetPlayerColor(playerid, COLOR_REALRED);
}
return 1;
}
CMD:adutyoff(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >=2)
{
new name[24],ostring[124];
GetPlayerName(playerid,name,sizeof(name));
format(ostring,sizeof(ostring),"Administrator %s is now off duty (Let The Admin Roleplay).",name);
SendClientMessageToAll(-1,ostring);
SetPlayerHealth(playerid, 100);
SetPlayerArmour(playerid, 100);
SetPlayerColor(playerid, COLOR_WHITE);
}
return 1;
}