Moin
In meinem Gamemode geht der Teamchat nicht. Und der normale auch nicht. man kann alles eingeben, aber es kommt nichts.
Hier mal mein Teamchat Script:
public OnPlayerText(playerid, text[])
{
if(Muted[playerid] == 1)
{
SendClientMessage(playerid, 0xFF0000AA, "You're muted!");
return 0;
}
if(text[0] == '#')
{
//TeamChat
new str[128], pn[24];
GetPlayerName(playerid, pn, 24);
format(str, 128, "[TEAM]%s: %s", pn, text[1]);
if(gTeam[playerid] == SPY || gTeam[playerid] == BODYGUARD || gTeam[playerid] == POLICE)
{
for(new i; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(gTeam[i] == SPY || gTeam[i] == BODYGUARD || gTeam[i] == POLICE)
{
SendClientMessage(i, 0xFFFF00AA, str);
}
}
}
}
if(gTeam[playerid] == TERRORIST)
{
for(new i; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(gTeam[i] == TERRORIST)
{
SendClientMessage(i, 0xFFFF00AA, str);
}
}
}
}
if(gTeam[playerid] == PSYCHO)
{
for(new i; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(gTeam[i] == PSYCHO)
{
SendClientMessage(i, 0xFFFF00AA, str);
}
}
}
}
return 0;
}
return 1;
}
public OnPlayerPrivmsg(playerid, recieverid, text[])
{
if(Muted[playerid] == 1)
{
SendClientMessage(playerid, 0xFF0000AA, "You're muted!");
return 0;
}
return 1;
}
//edit: Hab ein Warning:
D:\Dokumente und Einstellungen\Disturbed\Desktop\samp03asvr_R3_win32\gamemodes\PTPM.pwn(395) : warning 235: public function lacks forward declaration (symbol "OnPlayerPrivmsg")
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
1 Warning.