My admin chat not working for Trial Admins
#1

Hello guys.

Well I have a problem here..

Recently I tried to change so the lowest admin could too access /a(dmin), the admin chat. But well.. He can write in the chat but not see it.

Before I changed the code

Код:
CMD:admin(playerid, params[])
{
	if(PlayerInfo[playerid][pAdmin] >= 2) {
		if(!isnull(params)) {

			new szMessage[128];

			if(PlayerInfo[playerid][pAdmin] == 1) format(szMessage, sizeof(szMessage), "[Admin Chat]Server Moderator %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 2) format(szMessage, sizeof(szMessage), "[Admin Chat]{808000}[Junior Admin]{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 3) format(szMessage, sizeof(szMessage), "[Admin Chat]{008080}[General Admin]{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 4) format(szMessage, sizeof(szMessage), "[Admin Chat]{FFFF00}[Senior Admin]{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 1337) format(szMessage, sizeof(szMessage), "[Admin Chat]{FF00FF}[Head Admin]{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 1338) format(szMessage, sizeof(szMessage), "[Admin Chat]{FF0000}[Admin Director]{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 99998) format(szMessage, sizeof(szMessage), "[Admin Chat]{00FFFF}[Community Manager]{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 99999) format(szMessage, sizeof(szMessage), "[Admin Chat]{00FF00}[Community Owner]{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else format(szMessage, sizeof(szMessage), "* Undefined Admin (%i) %s: %s", PlayerInfo[playerid][pAdmin], GetPlayerNameEx(playerid), params);

			SendAdminMessage(COLOR_GREEN, szMessage);
			Log("logs/adminchat.log", szMessage);
		}
		else SendClientMessageEx(playerid, COLOR_WHITE, "USAGE: (/a)dmin [admin chat]");
	}
	return 1;
}
And when I changed it...

Код:
CMD:admin(playerid, params[])
{
	if(PlayerInfo[playerid][pAdmin] >= 1) {
		if(!isnull(params)) {

			new szMessage[128];

			if(PlayerInfo[playerid][pAdmin] == 1) format(szMessage, sizeof(szMessage), "[Admin Chat]{FFFFAA}Trial Admin{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 2) format(szMessage, sizeof(szMessage), "[Admin Chat]{008080} Junior Admin{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 3) format(szMessage, sizeof(szMessage), "[Admin Chat]{008080} General Admin{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 4) format(szMessage, sizeof(szMessage), "[Admin Chat]{FFFF00} Senior Admin{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 1337) format(szMessage, sizeof(szMessage), "[Admin Chat]{FF0000} Head Admin{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 1338) format(szMessage, sizeof(szMessage), "[Admin Chat]{FF0000} Developer{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 99998) format(szMessage, sizeof(szMessage), "[Admin Chat]{00FFFF} Community Manager{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else if(PlayerInfo[playerid][pAdmin] == 99999) format(szMessage, sizeof(szMessage), "[Admin Chat]{00FFFF} Community Owner{FFFFFF} %s: %s", GetPlayerNameEx(playerid), params);
			else format(szMessage, sizeof(szMessage), "* Undefined Admin (%i) %s: %s", PlayerInfo[playerid][pAdmin], GetPlayerNameEx(playerid), params);

			SendAdminMessage(COLOR_GREEN, szMessage);
			Log("logs/adminchat.log", szMessage);
		}
		else SendClientMessageEx(playerid, COLOR_WHITE, "USAGE: (/a)dmin [admin chat]");
	}
	return 1;
}
So my question is if you can see the problem?

Thanks for all help I can get.
Reply


Messages In This Thread
My admin chat not working for Trial Admins - by DavidSparks - 09.12.2014, 13:42
Re: My admin chat not working for Trial Admins - by ThaCrypte - 09.12.2014, 14:02
Re: My admin chat not working for Trial Admins - by Josh_Main - 09.12.2014, 14:04
Re: My admin chat not working for Trial Admins - by DavidSparks - 09.12.2014, 17:20
Re: My admin chat not working for Trial Admins - by Stinged - 09.12.2014, 17:41
Re: My admin chat not working for Trial Admins - by ThaCrypte - 15.12.2014, 07:07

Forum Jump:


Users browsing this thread: 1 Guest(s)