11.05.2013, 06:00
Hello all. I have a quick question regarding showing OnDuty or nothing if not on duty as an admin.
Basically what I want to do is if someone does /admins and an admin is on duty it should be like this:
Name_Lastname OnDuty/ReadyToHelp
And if hes not on duty it should say OffDuty instead.
Here is the code I tried to work on, it compiles and goes through but ingame it doesnt display OffDuty or OnDuty
Basically what I want to do is if someone does /admins and an admin is on duty it should be like this:
Name_Lastname OnDuty/ReadyToHelp
And if hes not on duty it should say OffDuty instead.
Here is the code I tried to work on, it compiles and goes through but ingame it doesnt display OffDuty or OnDuty
pawn Code:
new adminduty[64];
if(PlayerInfo[i][pAdminDuty] == 0)
{
adminduty = "OffDuty";
}
else if(PlayerInfo[i][pAdminDuty] == 1)
{
adminduty ="OnDuty/ReadyToHelp";
}
pawn Code:
format(string, sizeof(string), "[%s]: %s *[%s]*", atext, PlayerName(i), adminduty);
SendClientMessage(playerid, COLOR_WHITE, string);