IRC Echo problem - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: IRC Echo problem (
/showthread.php?tid=144725)
IRC Echo problem -
dcmd_crash - 28.04.2010
Ok, so I've just started re-writing my IRC echo script from to 0.2x to upgrade it to 0.3. I'm using Incognito's really nice, IRC plug-in. The problem is this:
pawn Код:
public
IRC_OnConnect(botid)
{
printf("*** IRC_OnConnect: Bot ID %d connected!", botid);
// Join the channel
JoinChannels(botid);
// Add the bot to the group
IRC_AddToGroup(gGroupID, botid);
return 1;
}
forward
JoinChannels(botid);
public
JoinChannels(botid)
{
IRC_JoinChannel(botid, IRC_CHANNEL);
IRC_JoinChannel(botid, CHAT_CHAN);
IRC_JoinChannel(botid, VIP_CHAN);
IRC_JoinChannel(botid, CREW_CHAN);
return 1;
}
The function I created above is supposed to join the bots to all channels, but they only join the first one (IRC_CHANNEL). What am I doing wrong here?
Re: IRC Echo problem -
dcmd_crash - 29.04.2010
Bump. Someone got some help?
Re: IRC Echo problem -
woot - 29.04.2010
I think it someone is made to prevent flooding bots. Try using a timer delay of 2-5sec.
Re: IRC Echo problem -
dcmd_crash - 29.04.2010
Quote:
Originally Posted by //exora
I think it someone is made to prevent flooding bots. Try using a timer delay of 2-5sec.
|
I tired that last night when I got no replies in this topic
pawn Код:
public
IRC_OnConnect(botid)
{
printf("*** IRC_OnConnect: Bot ID %d connected!", botid);
// Join the channel
SetTimerEx("JoinChannels", 5000, 0, "i", botid);
// Add the bot to the group
IRC_AddToGroup(gGroupID, botid);
return 1;
}
forward
JoinChannels(botid);
public
JoinChannels(botid)
{
IRC_JoinChannel(botid, IRC_CHANNEL);
IRC_JoinChannel(botid, CHAT_CHAN);
IRC_JoinChannel(botid, VIP_CHAN);
IRC_JoinChannel(botid, CREW_CHAN);
return 1;
}