onplayertext wont work on two scripts? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: onplayertext wont work on two scripts? (
/showthread.php?tid=362049)
onplayertext wont work on two scripts? -
vvhy - 23.07.2012
Problem is the one in my gamemode script will not send the message to my IRC channel
I have this in my gang script for gang chat.
pawn Код:
if(text[0] == '!')
{
if(!GetPlayerGang(playerid))
{
SendError(playerid,"you are not in a gang.");
return 0;
}
new string[200];
format(string,sizeof string,"[GANG CHAT]%s: %s",PlayerNameEx(playerid),text[1]);
for(new i=0; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(GetPlayerGang(i) == GetPlayerGang(playerid))
{
SendMessage(i,COLOR_GANG,string,150);
}
}
}
return 0;
}
return 1;
}
I have this in my gamemode script for IRC so I can monitor gang chat from my IRC
pawn Код:
if (text[0] == '!')
{
IRC_GroupSayEx(gGroupAdminID,IRC_CHAN2,"12[[GANG CHAT]] %s: %s",PlayerNameEx(playerid),text[1]);
return 0;
}