Admin chat
#1

Hi,

I tried to transform a /a chat command for me but it doesnt work well.


Код:
CMD:a(playerid, params[])
{
	new string[256];
	if(!(pInfo[playerid][Admin] >= 0)) return SendClientMessage(playerid, Rouge, "La commande entrйe est inconnue !");
	if(sscanf(params, "ui", params)) return SendClientMessage(playerid, Rouge, "Utilisation: /a [Votre Message]");
	GetPlayerName(playerid,joueuremetteur,sizeof(joueuremetteur));
	new rangadmin[64];
	if(pInfo[playerid][Admin] == 40) { rangadmin = "Rank 1"; }
	else if(pInfo[playerid][Admin] >= 90) { rangadmin = "Fondateur"; }
	else { rangadmin = "Unknown rank "; }
	
    format(string, 256, "%s  %s: %s", rangadmin, joueuremetteur, params);
    ChannelAdmin(Rouge, string);
	return 1;
}
Код:
public ChannelAdmin(color, string[])
{
	for(new i = 0; i < MAX_PLAYERS; i++)
	{
		if (pInfo[i][Admin] >= 1)
		{
			SendClientMessage(i, color, string);
		}
	}
	return 1;
}
When I use this command, everytime, the first letter of the string will be "я"
for exemple if I type /a test
I will have
"Fondateur Belabbas_Anis: яest"


How could I fix this please ?
Reply


Messages In This Thread
Admin chat - by anou1 - 18.01.2014, 21:49
Re: Admin chat - by -Jason - 18.01.2014, 21:56
Re : Admin chat - by anou1 - 18.01.2014, 21:57
Re: Admin chat - by -Jason - 18.01.2014, 22:17

Forum Jump:


Users browsing this thread: 1 Guest(s)