Register for your free account! | Forgot your password?

You last visited: Today at 17:33

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[RELEASE]Anti bot system 5165

Discussion on [RELEASE]Anti bot system 5165 within the CO2 PServer Guides & Releases forum part of the CO2 Private Server category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: May 2010
Posts: 630
Received Thanks: 130
[RELEASE]Anti bot system 5165

Here is an simple anti bot system.
Credits goes to Arco for the npc send thing

First go to MyThreads.cs and find:
Code:
            interval = Interval;
            T = new Thread(new ThreadStart(Run));
            T.Start();
Now under it paste:
Code:
                System.Timers.Timer BOTTimer = new System.Timers.Timer(1000.0);
                BOTTimer.Start();
                BOTTimer.Elapsed += delegate { BOT(); };
                System.Timers.Timer DBOTTimer = new System.Timers.Timer(1000.0);
                DBOTTimer.Start();
                DBOTTimer.Elapsed += delegate { BBOT(); };
Now find: bool closed = false;
under it paste:
Code:
        public static bool BOTSEND = false;
        public static bool DBOTSEND = false;
        public static bool BOTCHECK = false;
Now find:
Code:
        public void Close()
        {
            closed = true;
        }
above it put:
Code:
        public static void BOT()
        {
            if (DateTime.Now.Minute == 45 && BOTSEND == false)
            {
                foreach (Character Char in World.H_Chars.Values)
                {
                    DBOTSEND = false;
                    BOTSEND = true;
                    BOTCHECK = false;
                    Char.MyClient.DialogNPC = 13652;
                    PacketHandling.NPCDialog.Handle(Char.MyClient, null, 13652, 0);
                    Char.MyClient.EndSend();
                }
            }
        }

        public static void BBOT()
        {
            if (DateTime.Now.Minute == 15 && DBOTSEND == false)
            {
                    DBOTSEND = true;
                    BOTSEND = false;
                    BOTCHECK = true;
            }
        }
Then put this npc:
Code:
#region BOTTER
                            case 13652:
                                {
                                    if (Control == 0)
                                    {
                                        if (MyThread.BOTCHECK == false)
                                        {
                                            //Checking if players are afk, the way is that if they stand in same spot after 5secs count.
                                            GC.Message(2011, " CHECKING AFK PLAYERS.");
                                            ushort LASTSPOTX;
                                            ushort LASTSPOTY;
                                            ushort LASTSPOTM;
                                            LASTSPOTX = GC.MyChar.Loc.X;
                                            LASTSPOTY = GC.MyChar.Loc.Y;
                                            LASTSPOTM = GC.MyChar.Loc.Map;
                                            Thread.Sleep(5000);
                                            if (GC.MyChar.Loc.X == LASTSPOTX && GC.MyChar.Loc.Y == LASTSPOTY && GC.MyChar.Loc.Map == LASTSPOTM)
                                            {

                                            }
                                            else
                                            {
                                                GC.Message(2500, " ALL AFK PLAYERS ARE NOW OUT OF BOTSYSTEM.");
                                                Thread.Sleep(2000);
                                                GC.Message(2011, " ANTI BOT SYSTEM START IN 3SECONDS.");
                                                Thread.Sleep(3000);
                                                GC.AddSend(Packets.NPCSay("ANTI BOT SYSTEM: What color is red? ANSWER: RED"));
                                                GC.AddSend(Packets.NPCLink("Blue.", 1));
                                                GC.AddSend(Packets.NPCLink("Red.", 3));
                                                GC.AddSend(Packets.NPCLink("Gree.", 1));
                                                GC.AddSend(Packets.NPCLink("White.", 1));
                                                GC.AddSend(Packets.NPCLink("Yellow.", 1));
                                                GC.AddSend(Packets.NPCLink("Pink.", 1));
                                                GC.AddSend(Packets.NPCLink("Orange.", 1));
                                                GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                                GC.AddSend(Packets.NPCFinish());
                                            }
                                            if (Control == 1)
                                            {
                                                GC.MyChar.Teleport(6001, 50, 50);
                                                GC.Message(2005, GC.MyChar.Name + " Have been botjailed, because he answer wrong on the AntiBot System.");
                                            }
                                            if (Control == 3)
                                            {
                                                GC.AddSend(Packets.NPCSay("ANTI BOT SYSTEM: Wich of these things is not a vegetable? ANSWER: MEAT"));
                                                GC.AddSend(Packets.NPCLink("Salad.", 1));
                                                GC.AddSend(Packets.NPCLink("Tomato.", 1));
                                                GC.AddSend(Packets.NPCLink("Tomato again.", 1));
                                                GC.AddSend(Packets.NPCLink("WTF.", 1));
                                                GC.AddSend(Packets.NPCLink("OMG.", 1));
                                                GC.AddSend(Packets.NPCLink("Meat.", 4));
                                                GC.AddSend(Packets.NPCLink("Im blonde.", 1));
                                                GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                                GC.AddSend(Packets.NPCFinish());
                                            }
                                            if (Control == 4)
                                            {
                                                GC.AddSend(Packets.NPCSay("ANTI BOT SYSTEM: Say ok!!! ANSWER: OK"));
                                                GC.AddSend(Packets.NPCLink("OK.", 5));
                                                GC.AddSend(Packets.NPCLink("im a botter.", 1));
                                                GC.AddSend(Packets.NPCLink("noob.", 1));
                                                GC.AddSend(Packets.NPCLink("what ever.", 1));
                                                GC.AddSend(Packets.NPCLink("hey.", 1));
                                                GC.AddSend(Packets.NPCLink("lol.", 1));
                                                GC.AddSend(Packets.NPCLink("im a haxor.", 1));
                                                GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                                GC.AddSend(Packets.NPCFinish());
                                            }
                                            if (Control == 5)
                                            {
                                                GC.AddSend(Packets.NPCSay("ANTI BOT SYSTEM: What is 2+4? ANSWER: 6"));
                                                GC.AddSend(Packets.NPCLink("1.", 1));
                                                GC.AddSend(Packets.NPCLink("7.", 1));
                                                GC.AddSend(Packets.NPCLink("6.", 6));
                                                GC.AddSend(Packets.NPCLink("14.", 1));
                                                GC.AddSend(Packets.NPCLink("I can't count.", 1));
                                                GC.AddSend(Packets.NPCLink("BITCH.", 1));
                                                GC.AddSend(Packets.NPCLink("can i get botjail?.", 1));
                                                GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                                GC.AddSend(Packets.NPCFinish());
                                            }
                                            if (Control == 6)
                                            {
                                                GC.AddSend(Packets.NPCSay("ANTI BOT SYSTEM: Are you botting? ANSWER: no"));
                                                GC.AddSend(Packets.NPCLink("yes.", 1));
                                                GC.AddSend(Packets.NPCLink("yes.", 1));
                                                GC.AddSend(Packets.NPCLink("yes.", 1));
                                                GC.AddSend(Packets.NPCLink("yes.", 1));
                                                GC.AddSend(Packets.NPCLink("yes.", 1));
                                                GC.AddSend(Packets.NPCLink("yes.", 1));
                                                GC.AddSend(Packets.NPCLink("no.", 7));
                                                GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                                GC.AddSend(Packets.NPCFinish());
                                            }
                                            if (Control == 7)
                                            {
                                                GC.AddSend(Packets.NPCSay("Congratulations, your not a botter."));
                                                GC.AddSend(Packets.NPCLink("I know.", 255));
                                                GC.AddSend(Packets.NPCSetFace(N.Avatar));
                                                GC.AddSend(Packets.NPCFinish());
                                            }
                                        }
                                    }
                                    break;
                                }
                            #endregion
Now everytime the clock is XX:45, then it will send the antibot system

Note:
Quote:
Right click on Thread.Sleep and click resolve, then use System.Threading
.Summer is offline  
Thanks
4 Users
Old 05/14/2010, 00:19   #2
 
elite*gold: 0
Join Date: Sep 2008
Posts: 1,683
Received Thanks: 506
Why does this make you a reborn?

Talking about
Reborn += 1;
Basser is offline  
Thanks
1 User
Old 05/14/2010, 00:25   #3
 
elite*gold: 0
Join Date: May 2010
Posts: 630
Received Thanks: 130
oh, sorry, is because i changed reborn to bot count, in my source.
Thanks for notice me.

#Fixed
.Summer is offline  
Old 05/14/2010, 00:29   #4
 
gerble93's Avatar
 
elite*gold: 40
Join Date: Sep 2006
Posts: 1,890
Received Thanks: 805
You should also create a command/function that allows the player to indicate that they are currently AFK for a while so this way it ignores them and moves on..
gerble93 is offline  
Old 05/14/2010, 00:32   #5
 
killersub's Avatar
 
elite*gold: 0
Join Date: May 2009
Posts: 884
Received Thanks: 211
very nice job! +k
killersub is offline  
Old 05/14/2010, 00:54   #6
 
elite*gold: 0
Join Date: May 2010
Posts: 630
Received Thanks: 130
Quote:
Originally Posted by gerble93 View Post
You should also create a command/function that allows the player to indicate that they are currently AFK for a while so this way it ignores them and moves on..
it already check afk players.
but ill make command 2sec
.Summer is offline  
Old 05/14/2010, 00:55   #7


 
Korvacs's Avatar
 
elite*gold: 20
Join Date: Mar 2006
Posts: 6,126
Received Thanks: 2,518
Already got a way around your anti-bot check.

Since your npc always returns to the same dialog, and there is only 1 option which takes you to a different dialog (the correct one) any bot could be made to read the incoming bot check, and automatically answer by sending a dialog request to the only option which is different.

To easy.

If your wanting to go down the NPC Dialog anti-bot route, at the very least you should have all of the dialogs point to different dialog ids, instead of making it obvious like you have.

And if you really wanted to make something decent you should use the inputbox style link, and have the user input the answer to something, also dont put the answer in the dialog, since any proxy can parse that and create a database of questions and responses.

A good idea would be to ask the user something which changes quite often, for example what is your current level, what is your current hp, what is your current mp, how much gold is in your inv. Obviously databases can still be made and responses coded, but it would be alittle bit more complex than it is now.

Honestly though if you want anti-bot protection you should implement timestamp checking on incomming packets.
Korvacs is offline  
Thanks
1 User
Old 05/14/2010, 01:11   #8
 
elite*gold: 0
Join Date: May 2010
Posts: 630
Received Thanks: 130
Quote:
Originally Posted by Korvacs View Post
Already got a way around your anti-bot check.

Since your npc always returns to the same dialog, and there is only 1 option which takes you to a different dialog (the correct one) any bot could be made to read the incoming bot check, and automatically answer by sending a dialog request to the only option which is different.

To easy.

If your wanting to go down the NPC Dialog anti-bot route, at the very least you should have all of the dialogs point to different dialog ids, instead of making it obvious like you have.

And if you really wanted to make something decent you should use the inputbox style link, and have the user input the answer to something, also dont put the answer in the dialog, since any proxy can parse that and create a database of questions and responses.

A good idea would be to ask the user something which changes quite often, for example what is your current level, what is your current hp, what is your current mp, how much gold is in your inv. Obviously databases can still be made and responses coded, but it would be alittle bit more complex than it is now.

Honestly though if you want anti-bot protection you should implement timestamp checking on incomming packets.
it was just a simple anti bot system.
and yea is true, it could be done alot better.


@gerble
here is the afk command
-----------------------------------------------------
character.cs:
find: public ulong VP;

add this under:
Code:
public bool AFK;
Now open jump.cs
and replace the whole class with:
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace NewestCOServer.PacketHandling
{
    public class Jump
    {
        public static void Handle(Main.GameClient GC, byte[] Data)
        {
            if (GC.MyChar.AFK == false)
            {
                if (GC.MyChar.BuffOf(NewestCOServer.Features.SkillsClass.ExtraEffect.BlessPray).Eff == NewestCOServer.Features.SkillsClass.ExtraEffect.BlessPray)
                    GC.MyChar.RemoveBuff(GC.MyChar.BuffOf(Features.SkillsClass.ExtraEffect.BlessPray));
                GC.MyChar.Mining = false;
                GC.MyChar.AtkMem.Attacking = false;
                GC.MyChar.Action = 100;
                if (GC.MyChar.Loc.AbleToJump(BitConverter.ToUInt16(Data, 8), BitConverter.ToUInt16(Data, 10), GC.MyChar.StatEff.Contains(NewestCOServer.Game.StatusEffectEn.Cyclone) || GC.MyChar.StatEff.Contains(NewestCOServer.Game.StatusEffectEn.Ride)))
                {
                    if (GC.MyChar.StatEff.Contains(NewestCOServer.Game.StatusEffectEn.Ride))
                    {
                        if (GC.MyChar.Vigor >= 5)
                            GC.MyChar.Vigor -= 5;
                        else return;
                    }
                    Game.World.Action(GC.MyChar, Data);
                    GC.MyChar.Loc.Jump(BitConverter.ToUInt16(Data, 8), BitConverter.ToUInt16(Data, 10));
                    Game.World.Spawns(GC.MyChar, true);
                }
                else if (GC.MyChar.AFK == false)
                {
                    GC.LocalMessage(2005, "Invalid Jump!");
                    GC.AddSend(Packets.GeneralData(GC.MyChar.EntityID, 0, GC.MyChar.Loc.X, GC.MyChar.Loc.Y, 0x6c));
                }
            }
        }
    }
}
now open walkrun.cs
and replace the whole class with:
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace NewestCOServer.PacketHandling
{
    public class WalkRun
    {
        public static void Handle(Main.GameClient GC, byte[] Data)
        {
            if (GC.MyChar.AFK == false)
            {
                if (GC.MyChar.BuffOf(NewestCOServer.Features.SkillsClass.ExtraEffect.BlessPray).Eff == NewestCOServer.Features.SkillsClass.ExtraEffect.BlessPray)
                    GC.MyChar.RemoveBuff(GC.MyChar.BuffOf(Features.SkillsClass.ExtraEffect.BlessPray));
                GC.MyChar.Mining = false;
                GC.MyChar.AtkMem.Attacking = false;
                GC.MyChar.Action = 100;
                Game.World.Action(GC.MyChar, Data);
                GC.MyChar.Direction = (byte)(Data[4] % 8);
                GC.MyChar.Loc.Walk((byte)(Data[4] % 8));
                Game.World.Spawns(GC.MyChar, true);
            }
        }
    }
}
Now they can't walk or jump, when they are set as afk.
now in chat.cs find:
Code:
                    if (Cmd[0] == "/players")
                    {
above that put:
Code:
                    if (Cmd[0] == "/afk")
                    {
                        GC.LocalMessage(2000, "You are now set as AFK and you won't get effected by the anti bot system. You can't walk or jump!");
                        GC.MyChar.AFK = true;
                    }
                    if (Cmd[0] == "/afkoff")
                    {
                        GC.LocalMessage(2000, "You are not AFK more, feel free to walk and jump!");
                        GC.MyChar.AFK = false;
                    }
To make afk write: /afk
to make afk off write: /afkoff
.Summer is offline  
Old 05/14/2010, 01:55   #9
 
CIRASH's Avatar
 
elite*gold: 0
Join Date: Jul 2008
Posts: 259
Received Thanks: 73
Code:
GC.AddSend(Packets.NPCLink("[B][COLOR="Red"]Green.[/COLOR][/B]", 1));
CIRASH is offline  
Old 05/14/2010, 01:56   #10
 
-Shunsui-'s Avatar
 
elite*gold: 0
Join Date: Apr 2008
Posts: 1,152
Received Thanks: 321
this is more for AutoBots bot that do stuff for you? cause lol i can use about 500 other bots why not make a check to see if programs with containng name like "bot" and stuff like that and make em close and send a Messg
-Shunsui- is offline  
Old 05/14/2010, 02:00   #11
 
elite*gold: 0
Join Date: May 2010
Posts: 2
Received Thanks: 3
I believe it is illegal to look at search for something like that on somebodys computer although a nice TOS could save you from trouble.

EDIT: What if your botting a different game?
Fratua is offline  
Thanks
2 Users
Old 05/14/2010, 02:02   #12
 
elite*gold: 0
Join Date: May 2010
Posts: 630
Received Thanks: 130
cuz is jsut a simple bot checker
I dont have alot time for helping & making releases, since im working on my own server to make it done
so things i release will just be simple things

but to prevent bot programs, you could simply change your conquer.exe, so they would have to make a new bot for looking up the client.
then simply change your exe sometimes, (when patch?)
.Summer is offline  
Old 06/15/2010, 00:22   #13
 
elite*gold: 0
Join Date: Feb 2009
Posts: 700
Received Thanks: 79
Quote:
Originally Posted by Korvacs View Post
Already got a way around your anti-bot check.

Since your npc always returns to the same dialog, and there is only 1 option which takes you to a different dialog (the correct one) any bot could be made to read the incoming bot check, and automatically answer by sending a dialog request to the only option which is different.

To easy.

If your wanting to go down the NPC Dialog anti-bot route, at the very least you should have all of the dialogs point to different dialog ids, instead of making it obvious like you have.

And if you really wanted to make something decent you should use the inputbox style link, and have the user input the answer to something, also dont put the answer in the dialog, since any proxy can parse that and create a database of questions and responses.

A good idea would be to ask the user something which changes quite often, for example what is your current level, what is your current hp, what is your current mp, how much gold is in your inv. Obviously databases can still be made and responses coded, but it would be alittle bit more complex than it is now.

Honestly though if you want anti-bot protection you should implement timestamp checking on incomming packets.
Yep just like websites, they ask you what 5+1 is and you input the answer so a bot can't attack it. Btw .Summer, the changing .exe idea is a bad one. Maybe it's good temporarily until you find a way to block it for some time (not forever since hacks can always be updated). But having to change the .exe every patch just to prevent the bot, is bad. Trust me, a server I played did that and the outcome wasn't good.
copz1337 is offline  
Old 06/15/2010, 14:52   #14
 
elite*gold: 0
Join Date: Jun 2010
Posts: 95
Received Thanks: 11
Quote:
Originally Posted by copz1337 View Post
Yep just like websites, they ask you what 5+1 is and you input the answer so a bot can't attack it. Btw .Summer, the changing .exe idea is a bad one. Maybe it's good temporarily until you find a way to block it for some time (not forever since hacks can always be updated). But having to change the .exe every patch just to prevent the bot, is bad. Trust me, a server I played did that and the outcome wasn't good.
I have no idea on hax anyways
xStylo is offline  
Old 06/15/2010, 22:04   #15
 
elite*gold: 0
Join Date: Oct 2008
Posts: 342
Received Thanks: 66
the afk command just made it completly useless now
µ~Xero~µ is offline  
Reply


Similar Threads Similar Threads
[RELEASE] New System Anti Macro
09/18/2021 - EO PServer Guides & Releases - 18 Replies
hello guys, I do not know yet if it's a good idea, now that testing a new pet, give him was reborn remembered that there are people still using Macro after a thousand ways that will eventually discovered a way at once with this'm just using the following: cq_action delete from cq_action where id >= 6400050 and id <= 6400050; delete from cq_action where id >= 199633 and id <= 199648; INSERT INTO cq_action (id, id_next, id_nextfail, type, data, param) VALUES
[Release] 5165 Warehouses Auth System
04/01/2011 - CO2 PServer Guides & Releases - 18 Replies
this is just a simple Auth system for warehouses. It will ask for password (set from WHGuardian) each time players will open their warehouse. Attempt limit is not included in this release... btw; with this release, warehouseGuardian will now save the password in Character file. here are the screenshots: http://img408.imageshack.us/img408/6986/98867182. jpg Click The Image to see more screen shots 1. Go to NPCDialog.cs and search for this code: public static void...
[Release] Flower System (5165)
09/25/2010 - CO2 PServer Guides & Releases - 71 Replies
Heya! Mostly complete... just figure a way to save it on your server.... ScreenShots: http://img98.imageshack.us/img98/1949/164947279.j pg http://img714.imageshack.us/img714/5372/64922998. jpg http://img59.imageshack.us/img59/1025/64930238.jp g
[Release]NPC system 5165 simplified
05/10/2010 - CO2 PServer Guides & Releases - 14 Replies
//
PWABS: Anti-Ban System (Pre-Release Thread)
07/13/2009 - PW Hacks, Bots, Cheats, Exploits - 31 Replies
PWABS: Anti-Ban System By J250 Update: Added screenshots and updated help section. Hello everyone! Well, you may be thinking "Who is this guy?" "How can he stop me from getting banned?" "What is he on about?" Well, in answer to all but the first I am trying to create an application (Made using C#) to try and stop people from getting banned while botting, hacking or whatever you may be doing!



All times are GMT +1. The time now is 17:34.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.