CMD:adminduty(playerid, params[])
{
new string[64];
if (PlayerInfo[playerid][pAdminLevel] < 1) return SendClientMessage(playerid, 0xFF0000FF, "ERROR: You can't use this command!");
if (PlayerInfo[playerid][pAdminLevel] <= 3) return SendClientMessage(playerid, 0x868479FF, "TIP: Use /modduty to go on duty!");
{
format(string, sizeof(string), "ADMINDUTY: You are now admin on duty! (Your adminlevel is %s) ", pAdminLevel);
SendClientMessage(playerid, 0x00FF00FF, string);
PlayerInfo[playerid][pAdminDuty] = 1;
}
return 1;
}
Why using 2 commands? Why not use 1 command that toggle's it on or off by using a variable. In my opinion it would be more effective.
Here an example: pawn Код:
And in every of your teleport commands, add the codes that is shown below. pawn Код:
pawn Код:
This seems very complecated but once you get it its very simple, but I hope this helps. Regards, Rolyy |