I have this stock to show admin level name when an admin executes a command on a player:
But for some reason, this level name doesnt show.
Example command:
Player gets only "Despacito (0) has removed your warning log" but should be (example): "Owner Despacito (0) has removed your warning log."
Code:
stock AdminLevelName(playerid)
{
new szString[64];
switch (Player[playerid][Level])
{
case 1: szString = "[Trial Admin]";
case 2: szString = "[Moderator]";
case 3: szString = "[General Admin]";
case 4: szString = "[Manager]";
case 5: szString = "[Owner]";
}
return szString;
}
But for some reason, this level name doesnt show.
Example command:
Code:
CMD:resetwarns(playerid, params[])
{
new buf[128];
format(buf, sizeof(buf), "%s %s (%i) has removed your warning log.", AdminLevelName(playerid),ReturnPlayerName(playerid), playerid);
SendClientMessage(targetid, COLOR_PINKK, buf);
format(buf, sizeof(buf), "You have removed %s (%i)'s warning log.", ReturnPlayerName(targetid), targetid);
SendClientMessage(playerid, COLOR_PINKK, buf);
return 1;
}
Player gets only "Despacito (0) has removed your warning log" but should be (example): "Owner Despacito (0) has removed your warning log."