irc multi bot! help for +rep
#1

hey guys I was searching all over how to create multi bots like this :
WindyBot:
CandyBot:
WindyBot:
CandyBot:
WindyBot:
CandyBot:
1 time 1st bot says and the next time the 2nd bot says more explain:
WindyBot: Killer Has Joined The Server
CandyBot: Strike Has Joined The Server
how can I do that ?
Reply
#2

uhm...

use a variable, increase it each time a bot has said something.

when the variable is 0; let WindyBot say something;
when the variable is 1; let CandyBot say something;

or perhaps when the number is like: 2, 4, 6, 8, 10 etc; it'll use WindyBot; if it's 1, 3, 5, 7 etc; it'll use CandyBot;
like:
pawn Код:
new botcount = 0; // ontop of script.
// in callback
new botname[ 9 ];
botname = ( ( botcount % 2 == 0 ) ? ( "WindyBot" ) : ( "CandyBot" ) );
botcount++;
or you could do it randomly;

random example for connecting:
pawn Код:
new
    rand = random( 2 ),
    str[ 64 ],
    name[ MAX_PLAYER_NAME ],
    botname[ 9 ]
;
GetPlayerName( playerid, name, sizeof( name ) );
botname = ( rand == 0 ? ( "WindyBot"  ) : ( "CandyBot" ) );
format( str, sizeof( str ), "%s: %s has connected to the server!", botname, name );
SendClientMessageToAll( 0xFFFFFFFFFF, str );
Reply
#3

Add them to a group, then use IRC_GroupSay. See the example filterscript on how to do it.
Reply
#4

Quote:
Originally Posted by Vince
Посмотреть сообщение
Add them to a group, then use IRC_GroupSay. See the example filterscript on how to do it.
not sure if he meant IRC; didn't find anything in the post stating IRC; though I actually was wondering if he was talking about IRC;

ohwell.
Reply
#5

lol read the title , I was talking about how to make a multi bot candybot windybot candybot windybot what is the hard thing to understand it guys ?
Reply
#6

bump*
Reply
#7

Read my post again. -.-
Reply
#8

am sorry, but can you explain more to me.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)