Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -------------------------------------------------------------------------------------------------
- --DOWNLOAD LUA HACK KIT AT: http://b0mbnet.info/files/luahackkit.zip
- --FOR MORE INFO VISIT: http://b0mbnet.info/blog/2012/08/lua-hack-kit-you-put-a-what-in-my-what/
- -------------------------------------------------------------------------------------------------
- SetDebugPrivileges()
- local hwnd = 0
- while (hwnd == 0) do
- hwnd = FindWindow("Counter-Strike Source")
- end
- local procID = GetProcessId(hwnd)
- WriteConsole("Process ID: " .. tostring(procID) .. "\n")
- local procHandle = OpenProcess(PROCESS_ALL_ACCESS, procID)
- WriteConsole("Process Handle: " .. tostring(procHandle) .. " [" .. tostring(PROCESS_ALL_ACCESS) .. "]\n")
- local engine = GetBaseAddress(procHandle, "engine.dll")
- local client = GetBaseAddress(procHandle, "client.dll")
- local r_drawothermodels = client + 0x72F508
- --sigscan for \x89\x54\x24\x2C\x89\x44\x24\x30\xE8
- --then add 0xF to address found
- --resulting value = ptr to ptr to entity table
- local etbl = ReadInt(procHandle, engine + 0x3C6C88)
- WriteConsole("Entity Table @ " .. tostring(etbl) .. "\n");
- local GetEntity = function(idx)
- return ReadInt(procHandle, etbl + (40+(8*idx)))
- end
- local C_CSPlayer = {
- deadflag = function(base) return ReadInt(procHandle, base + 0x87) end,
- m_iHealth = function(base) return ReadInt(procHandle, base + 0x88) end,
- m_iTeamNum = function(base) return ReadInt(procHandle, base + 0x90) end,
- m_vecMins = function(base) return ReadFloat(procHandle, base + 0x168),
- ReadFloat(procHandle, base + 0x16C), ReadFloat(procHandle, base + 0x170) end,
- m_vecMaxs = function(base) return ReadFloat(procHandle, base + 0x174),
- ReadFloat(procHandle, base + 0x178), ReadFloat(procHandle, base + 0x17C) end,
- m_vecAbsOrigin = function(base) return ReadFloat(procHandle, base + 0x1F4),
- ReadFloat(procHandle, base + 0x1F8), ReadFloat(procHandle, base + 0x1FC) end,
- m_angAbsRotation = function(base) return ReadFloat(procHandle, base + 0x200),
- ReadFloat(procHandle, base + 0x204), ReadFloat(procHandle, base + 0x208) end,
- m_vecNetworkOrigin = function(base) return ReadFloat(procHandle, base + 0x20C),
- ReadFloat(procHandle, base + 0x210), ReadFloat(procHandle, base + 0x214) end,
- m_angNetworkAngles = function(base) return ReadFloat(procHandle, base + 0x218),
- ReadFloat(procHandle, base + 0x21C), ReadFloat(procHandle, base + 0x220) end,
- m_fFlags = function(base) return ReadInt(procHandle, base + 0x2DC) end,
- m_flFOVStart = function(base) return ReadFloat(procHandle, base + 0xF2C) end,
- m_bDucked = function(base) return ReadByte(procHandle, base + 0xD60) end,
- m_bDucking = function(base) return ReadByte(procHandle, base + 0xD61) end,
- m_flDucktime = function(base) return ReadFloat(procHandle, base + 0xD64) end,
- m_flFallVelocity = function(base) return ReadFloat(procHandle, base + 0xD74) end,
- m_nOldButtons = function(base) return ReadFloat(procHandle, base + 0xD78) end,
- m_vecPunchAngle = function(base) return ReadFloat(procHandle, base + 0xD88),
- ReadFloat(procHandle, base + 0xD8C), ReadFloat(procHandle, base + 0xD90) end,
- m_szLastPlaceName = function(base) return ReadStr(procHandle, base + 0x11A8, 20) end,
- m_flStamina = function(base) return ReadFloat(procHandle, base + 0x1380) end,
- }
- local o_EyeP = engine + 0x3E80A0
- local o_EyeYaw = engine + 0x3E80A4
- local o_EyeR = engine + 0x3E80A8
- WriteConsole("ACTIVATED\n");
- local function AngleToTarget(pX,pY,pZ, tX,tY,tZ)
- deltaX = pX - tX
- deltaY = pY - tY
- deltaZ = pZ - tZ
- hpy = math.sqrt((deltaX*deltaX) + (deltaY*deltaY))
- angP = math.deg(math.atan(deltaZ / hyp))
- angY = math.deg(math.atan(deltaY / deltaX))
- angR = 0
- if (deltaX >= 0) then deltaY += 180 end
- return angP,angY,angR
- end
- local tmp = 0
- local aimbot = false
- local abot_backup = 0
- while (IsKeyDown(VK_END) == 0) do --END
- if (IsKeyDown(VK_F11) == 1) then
- if (ReadInt(procHandle, r_drawothermodels) == 1) then
- WriteInt(procHandle, r_drawothermodels, 2)
- WriteConsole("wallhack on\n")
- else
- WriteInt(procHandle, r_drawothermodels, 1)
- WriteConsole("wallhack off\n")
- end
- end
- if (IsKeyDown(VK_F10) == 1) then
- aimbot = not aimbot
- if (aimbot) then WriteConsole("Aimbot on\n")
- else WriteConsole("Aimbot off\n") end
- end
- if (aimbot) then
- local Me = GetEntity(1)
- local EyeX, EyeY, EyeZ = C_CSPlayer.m_vecNetworkOrigin(Me)
- WriteConsole("Local Pos: " .. tostring(EyeX) .. ", "
- .. tostring(EyeY) .. ", " .. tostring(EyeZ) .. "\n")
- local Nme = GetEntity(2)
- local NmeX, NmeY, NmeZ = C_CSPlayer.m_vecNetworkOrigin(Nme)
- if (C_CSPlayer.m_bDucked(Nme) == 1) then
- NmeZ = NmeZ + 32 else NmeZ = NmeZ + 65 end
- WriteConsole("Enemy Pos: " .. tostring(NmeX) .. ", "
- .. tostring(NmeY) .. ", " .. tostring(NmeZ) .. "\n")
- local pitch, yaw, roll = AngleToTarget(EyeX,EyeY,EyeZ, NmeX,NmeY,NmeZ)
- WriteConsole("Angle to target: " .. tostring(pitch) .. ", "
- .. tostring(yaw) .. ", " .. tostring(roll) .. "\n")
- WriteFloat(procHandle, o_EyeP, math.NormalizeAngle(pitch))
- WriteFloat(procHandle, o_EyeYaw, math.NormalizeAngle(yaw))
- end
- Sleep(100)
- end
- CloseHandle(procHandle)
Add Comment
Please, Sign In to add comment