Example #1
0
        static void GetListaEntidades(GerenciaMemoria gMem)
        {
            int end;

            end        = gMem.EncontraPadrao(new byte[] { 0xBB, 0x00, 0x00, 0x00, 0x00, 0x83, 0xFF, 0x01, 0x0F, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x3B, 0xF8 }, "x????xxxxx????xx", gMem.endBaseCliente, gMem.tamModuloCliente) + 1;
            EntityList = gMem.Read <int>(gMem.endBaseCliente + end) - gMem.endBaseCliente.ToInt32();
        }
Example #2
0
 // A function that adds a color around the players, being visible through the wall
 public void SetGlow(Player jogador, GerenciaMemoria gMem, Color color)
 {
     gMem.Write(glowObj + (jogador.glowIndex * 0x38 + 0x24), 1);
     gMem.Write(glowObj + (jogador.glowIndex * 0x38 + 0x25), 0);
     gMem.Write(glowObj + (jogador.glowIndex * 0x38 + 0x26), 0);
     gMem.Write(glowObj + (jogador.glowIndex * 0x38 + 0x4), color);
 }
Example #3
0
        static void GetBaseObjeto(GerenciaMemoria gMem)
        {
            int end;

            end        = gMem.EncontraPadrao(new byte[] { 0xE8, 0x0, 0x0, 0x0, 0x0, 0x83, 0xC4, 0x04, 0xB8, 0x0, 0x0, 0x0, 0x0, 0xC3, 0xcc }, "x????xxxx????xx", gMem.endBaseCliente, gMem.tamModuloCliente) + 9;
            ObjectBase = gMem.Read <int>(gMem.endBaseCliente + end) - gMem.endBaseCliente.ToInt32();
        }
Example #4
0
        static void GetPlayerLocal(GerenciaMemoria gMem)
        {
            int end;

            end         = gMem.EncontraPadrao(new byte[] { 0xFC, 0xE8, 0x00, 0x00, 0x00, 0x00, 0x8B, 0x3D }, "xx????xx", gMem.endBaseCliente, gMem.tamModuloCliente) + 8;
            LocalPlayer = gMem.Read <int>(gMem.endBaseCliente + end) - gMem.endBaseCliente.ToInt32();
        }
Example #5
0
 // Gives you offsets information
 public Player(GerenciaMemoria gMem, int index)
 {
     baseAddr   = (IntPtr)gMem.Read <uint>(gMem.endBaseCliente + Offsets.EntityList + ((index - 1) * 16));
     this.index = index;
     vida       = gMem.Read <int>(baseAddr + Offsets.CSPlayer.health);
     glowIndex  = gMem.Read <int>(baseAddr + Offsets.CSPlayer.glowIndex);
     time       = gMem.Read <int>(baseAddr + Offsets.CSPlayer.teamNum);
     dormente   = gMem.Read <bool>(baseAddr + Offsets.CSPlayer.m_bDormant);
     estaVivo   = vida > 0;
 }
Example #6
0
 // Check the number of players in the match in a maximum of 64
 public ListaEntidades(GerenciaMemoria gMem)
 {
     local = new LocalPlayer(gMem);
     for (int i = 0; i < 64; i++)
     {
         if (i != local.index)
         {
             jogadores.Add(new Player(gMem, i));
         }
     }
 }
Example #7
0
        static void Main(string[] args)
        {
            GerenciaMemoria gMem;
            bool            radarOn = true, espOn = true;

            Console.WriteLine("Esperando abrir csgo!");
            Console.Title = "csgoHAX radar + wallhack by Drão";

            // Repeat structure waiting for the game to be opened
            do
            {
                gMem = new GerenciaMemoria();
            } while (!gMem.Inicia());

            Console.WriteLine("Jogo encontrado!");
            Console.WriteLine(">Atualizando Hack!");

            // Update the offsets to not write in memory in the wrong places and take untrusted
            Offsets.AtualizaOffsets(gMem);

            Console.WriteLine("Jogador Local: " + Offsets.LocalPlayer.ToString("X"));
            Console.WriteLine("Base do Objeto: " + Offsets.ObjectBase.ToString("X"));
            Console.WriteLine("Lista de Entidades: " + Offsets.EntityList.ToString("X"));
            Console.WriteLine("\n>HACK ATIVADO!");
            Console.WriteLine("\nF6 Liga/Desliga Wallhack");
            Console.WriteLine("F7 Liga/Desliga radar HACK\n");

            // Repeat structure is always waiting for writing in memory, waiting for keys to be pressed, updating radar, changing glow color depending on the life, etc.
            while (true)
            {
                // Checks if the F7 key has been pressed and changes the value of the bool variable
                if (Convert.ToBoolean(GetAsyncKeyState(0x76) & 1))
                {
                    radarOn = !radarOn;
                    Console.WriteLine("Radar: " + radarOn);
                }

                // Checks if the F6 key has been pressed and changes the value of the bool variable
                if (Convert.ToBoolean(GetAsyncKeyState(0x75) & 1))
                {
                    espOn = !espOn;
                    Console.WriteLine("Wallhack: " + espOn);
                }

                ListaEntidades entList = new ListaEntidades(gMem);
                Wallhack       wh      = new Wallhack((IntPtr)gMem.Read <uint>(gMem.endBaseCliente + Offsets.ObjectBase));

                foreach (var jogador in entList.jogadores)
                {
                    // If player is alive and dormant (dead player) is alive)
                    if (jogador.estaVivo && !jogador.dormente)
                    {
                        // If player is of the enemy team
                        if (jogador.time != entList.local.time)
                        {
                            // The displays on the radar
                            if (radarOn)
                            {
                                wh.SetSpotted(jogador, gMem);
                            }

                            // Changes the color of the glow of the enemy team, depending on the life, 100 HP equal to green
                            if (espOn)
                            {
                                wh.SetGlow(jogador, gMem, new Color(255 - jogador.vida * 2.55f, jogador.vida * 2.55f, 0));
                            }
                        }
                        else
                        {
                            /* Changes the glow color of the own team
                             * if (espOn)
                             *  wh.SetGlow(jogador, gMem, new Color(0, 0, 255.0f));
                             */
                        }
                    }
                }
                // Sleep to avoid overloading the processor and loss of fps
                Thread.Sleep(1);
            }
        }
Example #8
0
 // Radar hack, function displays the enemy player on the radar of the game itself
 public void SetSpotted(Player player, GerenciaMemoria Mem)
 {
     Mem.Write(player.baseAddr + Offsets.CSPlayer.bSpotted, true);
 }
Example #9
0
 public Player GetPlayer(GerenciaMemoria gMem, int index)
 {
     return(new Player(gMem, index));
 }
Example #10
0
 public LocalPlayer(GerenciaMemoria gMem)
 {
     baseAddr = (IntPtr)gMem.Read <uint>(gMem.endBaseCliente + Offsets.LocalPlayer);
     index    = gMem.Read <int>(baseAddr + Offsets.CSPlayer.index);
     time     = gMem.Read <int>(baseAddr + Offsets.CSPlayer.teamNum);
 }
Example #11
0
 public static void AtualizaOffsets(GerenciaMemoria gMem)
 {
     GetPlayerLocal(gMem);
     GetBaseObjeto(gMem);
     GetListaEntidades(gMem);
 }