[Release] Aimbot

06/12/2009 06:08 Zeroxelli#1
Well, Vortex. mentioned it and I was bored. So, here you go.

For Handlers/Chat.cs put:
Code:
                        #region Automation
                        case "aimbot":
                            {
                                if (Command.Length >= 2)
                                {
                                    switch (Command[1])
                                    {
                                        case "stop":
                                            {
                                                Automation.Automation.Going.Remove(CSocket.Client.ID);
                                                CSocket.Send(ConquerPacket.Chat(0, "SYSTEM", CSocket.Client.Name, "[Aimbot] Aimbot thread stopped.", Struct.ChatType.Top));
                                                break;
                                            }
                                        default:
                                            {
                                                string Name = Command[1].ToString();
                                                int wType = int.Parse(Command[2]);
                                                foreach (ClientSocket CSock in Nano.ClientPool.Values)
                                                {
                                                    if (CSock.Client.Name == Name)
                                                    {
                                                        Character Aim = CSock.Client;
                                                        Dictionary<ClientSocket, Character> Objective = new Dictionary<ClientSocket, Character>();
                                                        Objective.Add(CSocket, Aim);
                                                        if (Automation.Automation.Aimbots.ContainsKey(CSocket.Client.ID))
                                                            Automation.Automation.Aimbots.Remove(CSocket.Client.ID);
                                                        Automation.Automation.Aimbots.Add(CSocket.Client.ID, Objective);
                                                        Automation.Automation.LastAimbot = CSocket.Client.ID;
                                                        Automation.Automation.LastAimSID = wType;
                                                        if (!Automation.Automation.Going.Contains(CSocket.Client.ID))
                                                            Automation.Automation.Going.Add(CSocket.Client.ID);
                                                        new Thread(Automation.Automation.AimBot).Start();
                                                        CSocket.Send(ConquerPacket.Chat(0, "SYSTEM", CSocket.Client.Name, "[Aimbot] Aimbot thread started, use `/aimbot stop` to kill it.", Struct.ChatType.Top));
                                                    }
                                                }
                                                break;
                                            }
                                    }
                                }
                                break;
                            }
                        #endregion Automation
And in the Handlers folder make a new file named Aimbot.cs, and in it put:
Code:
using System;
using CoEmu_v2_GameServer.Connections;
using CoEmu_v2_GameServer.Entities;
using CoEmu_v2_GameServer.Calculations;
using CoEmu_v2_GameServer.Handlers;
using System.Threading;
using System.Collections.Generic;
using CoEmu_v2_GameServer.Packets;
using CoEmu_v2_GameServer.Structs;

namespace CoEmu_v2_GameServer.Automation
{
    public class Automation
    {
        public static Dictionary<int, Dictionary<ClientSocket, Character>> Aimbots = new Dictionary<int, Dictionary<ClientSocket, Character>>();
        public static int LastAimbot;
        public static int LastAimSID;
        public static List<int> Going = new List<int>();
        public static void AimBot()
        {
            Dictionary<ClientSocket, Character> Object = Aimbots[LastAimbot];
            foreach (KeyValuePair<ClientSocket, Character> CSobj in Object)
            {
                ClientSocket CSocket = CSobj.Key;
                Character Aim = CSobj.Value;
                int SkillID = (LastAimSID == 1 ? 1045 : 1046);

                if (SkillID == 1045 && !CSocket.Client.Skills.ContainsKey(1045))
                {
                    CSocket.Send(ConquerPacket.Chat(0, "SYSTEM", CSocket.Client.Name, "[Aimbot] You must learn FastBlade first.", Struct.ChatType.Top));
                    break;
                }

                if (SkillID == 1046 && !CSocket.Client.Skills.ContainsKey(1046))
                {
                    CSocket.Send(ConquerPacket.Chat(0, "SYSTEM", CSocket.Client.Name, "[Aimbot] You must learn ScentSword first.", Struct.ChatType.Top));
                    break;
                }

                while (Going.Contains(CSocket.Client.ID))
                {
                    if (CSocket.Client.CurrentStam >= 22)
                    {
                        if (!Nano.ClientPool.ContainsKey(Aim.ID))
                        {
                            CSocket.Send(ConquerPacket.Chat(0, "SYSTEM", CSocket.Client.Name, "[Aimbot] User logged off, seizing thread.", Struct.ChatType.Top));
                            break;
                        }
                        else if (!Aim.Dead)
                        {
                            if ((int)Aim.Map == (int)CSocket.Client.Map)
                            {
                                if (Calculation.InRange(CSocket.Client.X, CSocket.Client.Y, Aim.X, Aim.Y, 9))
                                {
                                    Handler.NoTargetMagic(CSocket, SkillID, Aim.X, Aim.Y);
                                }
                            }
                            else
                            {
                                CSocket.Send(ConquerPacket.Chat(0, "SYSTEM", CSocket.Client.Name, "[Aimbot] Aimbot cannot track characters not in your map.", Structs.Struct.ChatType.Top));
                                break;
                            }
                        }
                    }
                    Thread.Sleep(1000);
                }
                break;
            }
            Thread.CurrentThread.Abort();
        }
    }
}
It's really only for a joke, so I won't provide support. The version in my server has a lot more checks, I just don't feel like shelling all my functions out (Lazy). Anyway, have fun.

EDIT: By the way, at the top of chat.cs you may wanna add
Code:
using CoEmu_v2_GameServer.Automation;
06/12/2009 06:10 Rulzan#2
your the best,you helpd me a lot
06/12/2009 06:11 Zeroxelli#3
Quote:
Originally Posted by Rulzan View Post
your the best,you helpd me a lot
Woot xD
06/12/2009 06:44 Zimbolt#4
need impoot men +k +k +k
Somthing like that.
Edit : Regarding arab4life
You act like I care who you are. That's the funny part.
06/12/2009 07:39 arab4life#5
Quote:
Originally Posted by Zimbolt View Post
need impoot men +k +k +k
Somthing like that.
fag
06/12/2009 07:41 Zeroxelli#6
Quote:
Originally Posted by Zimbolt View Post
need impoot men +k +k +k
Somthing like that.
Quote:
Originally Posted by arab4life View Post
fag
........I don't get it.
06/12/2009 07:43 arab4life#7
Quote:
Originally Posted by Zeroxelli View Post
........I don't get it.
long story - i wish he knew who i am
06/12/2009 07:44 Zeroxelli#8
Quote:
Originally Posted by arab4life View Post
long story - i wish he knew who i am
Rofl, I wish everyone knew who I am. Though, I'd probably get banned for my reputation on the interwebz. xD
06/12/2009 10:03 Rulzan#9
hey hey this topic is for this relase guys
06/12/2009 12:18 PurePwnage23#10
I Got a error :( The type or namespace name 'Automation' does not exist in the namespace 'CoEmu_v2_GameServer' (are you missing an assembly reference?)
06/12/2009 12:26 yuko#11
nice nice, but whats the use of this.
where is the fun of aiming someone without doing anything yourself
if you wanna kill someone just make a kill command.

i feel sorry for those who use this

@Zeroxelli
nice work ;)
06/12/2009 13:32 Zanzibar#12
Wow, this is pretty epic.

Epic win in FB &+ SS fights.
06/12/2009 14:05 Vortex.#13
This is, alright. Your using way too much mem, mine is a simple. Works great
06/12/2009 14:27 _Emme_#14
Quote:
Originally Posted by Vortex. View Post
This is, alright. Your using way too much mem, mine is a simple. Works great

The ironic thing is that you copied your from Kinshi's source, or atleast parts since you two uses the exact same variables and the same code on some parts.

I still belive mine is the simplest.
06/12/2009 14:35 Vortex.#15
I didn't copy shit from, Kinshi's source.