Beispiel #1
0
        private static void DrawPlayerGlow(PlayerGlowStruct playerStruct, int glowIndex)
        {
            //We ge the glow object manager
            var glowObjectManager = PinvokeWrapper.ReadAddInt(Utils.ClientBaseAddress + Offsets.dwGlowObjectManager, Utils.CsgoHandle);

            //We write the struct to memory
            PinvokeWrapper.WriteFloat((IntPtr)glowObjectManager + glowIndex * 0x38 + 0x4, Utils.CsgoHandle, playerStruct.Red);
            PinvokeWrapper.WriteFloat((IntPtr)glowObjectManager + glowIndex * 0x38 + 0x8, Utils.CsgoHandle, playerStruct.Green);
            PinvokeWrapper.WriteFloat((IntPtr)glowObjectManager + glowIndex * 0x38 + 0xC, Utils.CsgoHandle, playerStruct.Blue);
            PinvokeWrapper.WriteFloat((IntPtr)glowObjectManager + glowIndex * 0x38 + 0x10, Utils.CsgoHandle, playerStruct.Alpha);
            PinvokeWrapper.WriteFloat((IntPtr)glowObjectManager + glowIndex * 0x38 + 0x10, Utils.CsgoHandle, playerStruct.Alpha);
            PinvokeWrapper.WriteBool((IntPtr)glowObjectManager + glowIndex * 0x38 + 0x24, Utils.CsgoHandle, playerStruct.RenderOccluded);
            PinvokeWrapper.WriteBool((IntPtr)glowObjectManager + glowIndex * 0x38 + 0x25, Utils.CsgoHandle, playerStruct.RenderUnoccluded);
        }
Beispiel #2
0
        private static void WallHack()
        {
            //We create a struct with the desired color for the enemy players
            var enemyStruct = new PlayerGlowStruct(255f, 0f, 0f, 1f, true, false);    //Red color
            //We create a struct with the desired color for the allies
            var friendStruct = new PlayerGlowStruct(0f, 255f, 0f, 0.8f, true, false); //Green color

            while (Options.GlowHackIsEnabled)
            {
                var players = Utils.GetPlayers();

                //If there are no players, we continue looping until there is one
                if (players.Count == 0)
                {
                    continue;
                }

                //We get our local player
                var localPlayer = Utils.GetLocalPlayer();

                foreach (var currentPlayer in players)
                {
                    //We exclude players that are dead or they are dormant
                    if (currentPlayer.GetHealth() == 0 || currentPlayer.IsDormant())
                    {
                        continue;
                    }

                    if (currentPlayer.GetTeam() != localPlayer.GetTeam())
                    {
                        //Enable player on radar
                        PinvokeWrapper.WriteBool((IntPtr)currentPlayer.BaseAddress + Offsets.m_bSpotted, Utils.CsgoHandle, true);
                        //Draw enemy glow
                        DrawPlayerGlow(enemyStruct, currentPlayer.GetGlowIndex());
                    }
                    else
                    {
                        //Draw friend
                        DrawPlayerGlow(friendStruct, currentPlayer.GetGlowIndex());
                    }
                }

                Thread.Sleep(2);
            }
        }