Admin Duty
#1

Could anyone help me to make commands like " /aduty " it will allow the admin hide their Last Name (RP Server).. and changed the Name Tag color into Red ?
Reply
#2

Try this 1.


CMD:aduty(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] < 2) return SendClientMessage(playerid, -1, "This is an admin only command!");
if(PlayerInfo[playerid][pAdminDuty] == 0)
{

SendClientMessageEx(playerid, COLOR_YELLOW, "You are now on administrative duty! Remember to check /reports!");
PlayerInfo[playerid][pAdminDuty] = 1;
SetPlayerHealth(playerid, 100000);
SetPlayerArmour(playerid, 100000);
SetPlayerColor(playerid, 0xFFFFFFAA);
new string[128];
format(string, sizeof(string), "Administrator %s is now on Admin Duty! (/report for assistance)", GetPlayerNameEx(playerid));
SendClientMessageToAllEx(COLOR_YELLOW, string);
}
else
{
SendClientMessageEx(playerid, COLOR_RED, "You are now off admin duty!");
SetPlayerHealth(playerid, 100);
SetPlayerArmour(playerid, 0);
PlayerInfo[playerid][pAdminDuty] = 0;
}
return 1;
}
Reply
#3

pawn Код:
E:\Grand City Roleplay Indonesia Ver.2.6(x)\gamemodes\NGRP_nomysql.pwn(751) : error 001: expected token: ";", but found "new"
E:\Grand City Roleplay Indonesia Ver.2.6(x)\gamemodes\NGRP_nomysql.pwn(28658) : error 017: undefined symbol "pAdminDuty"
E:\Grand City Roleplay Indonesia Ver.2.6(x)\gamemodes\NGRP_nomysql.pwn(28662) : error 017: undefined symbol "pAdminDuty"
E:\Grand City Roleplay Indonesia Ver.2.6(x)\gamemodes\NGRP_nomysql.pwn(28673) : error 017: undefined symbol "pAdminDuty"
E:\Grand City Roleplay Indonesia Ver.2.6(x)\gamemodes\NGRP_nomysql.pwn(85415) : warning 203: symbol is never used: "AdminDuty"
Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
I Got these errors
Reply
#4

Try
this in top

#Define aduty 1
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)