if(strcmp(subcmd, "italian", true) == 0))
{
if(PlayerInfo[playerid][pMember] == 14)
{
GetPlayerName(playerid, playername, sizeof(playername));
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' '))
{idx++;}
new offset = idx;
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{result[idx - offset] = cmdtext[idx]; idx++;}
result[idx - offset] = EOS;
if(!strlen(result))
{
SendClientMessage(playerid, COLOR_FACTION, "[Action] /mafia italian [texte]>");
return 1;
}
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid,x,y,z);
print("Lancement Boucle 86");
for(new p = 0; p < MAX_PLAYERS; p++)
{
if(IsPlayerConnected(p))
{
if(PlayerToPoint(20, p, x, y, z))
{
if(PlayerInfo[p][pMember] == 14)
{
format(string, sizeof(string), "%s dit: [Italian] %s", playername, result);
ProxDetector(20.0, playerid, string,COLOR_CHAT1,COLOR_CHAT2,COLOR_CHAT3,COLOR_CHAT4,COLOR_CHAT5,true);
return 1;
}
else
{
format(string, sizeof(string), "%s dit: [Unknow Language]", playername);
ProxDetector(20.0, playerid, string,COLOR_CHAT1,COLOR_CHAT2,COLOR_CHAT3,COLOR_CHAT4,COLOR_CHAT5,true);
return 1;
}
}
}
}
print("End Boucle 86");
}
format(string, sizeof(string), "%s dit: [Italian] %s", playername, result);
ProxDetector(20.0, playerid, string,COLOR_CHAT1,COLOR_CHAT2,COLOR_CHAT3,COLOR_CHAT4,COLOR_CHAT5,true);
return 1;
The thing is, when he speak, Ok, people see [Italian] as they don't understand. But people who are also italian, in the mafia, see [Italian] too. And when someone try /mafia italian <text> he can't se what he's writing, or what the others are saying. The only way that he see what he's writing is to don't be near a player. |