Updated offsets and offset names to match cs2-dumper

This commit is contained in:
IMXNOOBX
2023-10-22 14:01:24 +02:00
parent d9b3338bf8
commit 2e7353ba20
5 changed files with 20 additions and 18 deletions
+3 -1
View File
@@ -29,7 +29,9 @@ Simple external esp using gdi overlay to render esp boxes on top of cs2 highligh
* To manually update the esp offsets i have included an offsets.json file which will be created once opened. * To manually update the esp offsets i have included an offsets.json file which will be created once opened.
1. Go to this [unknowncheats thread](https://www.unknowncheats.me/forum/counter-strike-2-a/576077-counter-strike-2-reversal-structs-offsets.html) and find the latest offsets posted by the community 1. Two ways to get the latest offsets.
1.1 Go to this [unknowncheats thread](https://www.unknowncheats.me/forum/counter-strike-2-a/576077-counter-strike-2-reversal-structs-offsets.html) and find the latest offsets posted by the community
1.2 Or go to this repository [cs2-dumper](https://github.com/a2x/cs2-dumper) and find the latest offstes
2. You will find somethig like this 2. You will find somethig like this
+5 -5
View File
@@ -223,10 +223,10 @@ namespace updater {
offsets::m_ArmorValue = data["m_ArmorValue "]; offsets::m_ArmorValue = data["m_ArmorValue "];
if (data["m_iHealth"].is_number()) if (data["m_iHealth"].is_number())
offsets::m_iHealth = data["m_iHealth"]; offsets::m_iHealth = data["m_iHealth"];
if (data["dwPlayerPawn"].is_number()) if (data["m_hPlayerPawn"].is_number())
offsets::dwPlayerPawn = data["dwPlayerPawn"]; offsets::m_hPlayerPawn = data["m_hPlayerPawn"];
if (data["dwSanitizedName"].is_number()) if (data["dwSanitizedName"].is_number())
offsets::dwSanitizedName = data["dwSanitizedName"]; offsets::m_sSanitizedPlayerName = data["m_sSanitizedPlayerName"];
if (data["m_iTeamNum"].is_number()) if (data["m_iTeamNum"].is_number())
offsets::m_iTeamNum = data["m_iTeamNum"]; offsets::m_iTeamNum = data["m_iTeamNum"];
if (data["m_vecOrigin"].is_number()) if (data["m_vecOrigin"].is_number())
@@ -259,8 +259,8 @@ namespace updater {
data["m_pClippingWeapon"] = offsets::m_pClippingWeapon; data["m_pClippingWeapon"] = offsets::m_pClippingWeapon;
data["m_ArmorValue"] = offsets::m_ArmorValue; data["m_ArmorValue"] = offsets::m_ArmorValue;
data["m_iHealth"] = offsets::m_iHealth; data["m_iHealth"] = offsets::m_iHealth;
data["dwPlayerPawn"] = offsets::dwPlayerPawn; data["m_hPlayerPawn"] = offsets::m_hPlayerPawn;
data["dwSanitizedName"] = offsets::dwSanitizedName; data["m_sSanitizedPlayerName"] = offsets::m_sSanitizedPlayerName;
data["m_iTeamNum"] = offsets::m_iTeamNum; data["m_iTeamNum"] = offsets::m_iTeamNum;
data["m_vecOrigin"] = offsets::m_vecOrigin; data["m_vecOrigin"] = offsets::m_vecOrigin;
+7 -7
View File
@@ -30,14 +30,14 @@ namespace updater {
const inline std::string github_repo_api = "https://api.github.com/repos/IMXNOOBX/cs2-external-esp/commits"; const inline std::string github_repo_api = "https://api.github.com/repos/IMXNOOBX/cs2-external-esp/commits";
const inline std::string raw_updated_offets = "https://github.com/IMXNOOBX/cs2-external-esp/raw/main/offsets/offsets.json"; const inline std::string raw_updated_offets = "https://github.com/IMXNOOBX/cs2-external-esp/raw/main/offsets/offsets.json";
inline int build_number = 13963; inline int build_number = 13964;
namespace offsets { namespace offsets {
inline std::ptrdiff_t dwLocalPlayer = 0x17E27C8; inline std::ptrdiff_t dwLocalPlayer = 0x17E7158;
inline std::ptrdiff_t dwEntityList = 0x1793DC8; inline std::ptrdiff_t dwEntityList = 0x1798738;
inline std::ptrdiff_t dwViewMatrix = 0x1881D70; inline std::ptrdiff_t dwViewMatrix = 0x1886710;
inline std::ptrdiff_t dwBuildNumber = 0x487514; inline std::ptrdiff_t dwBuildNumber = 0x487514;
inline std::ptrdiff_t dwPlantedC4 = 0x1887FC0; inline std::ptrdiff_t dwPlantedC4 = 0x188CAD0;
inline std::ptrdiff_t m_flC4Blow = 0xEB0; inline std::ptrdiff_t m_flC4Blow = 0xEB0;
inline std::ptrdiff_t m_flNextBeep = 0xEAC; inline std::ptrdiff_t m_flNextBeep = 0xEAC;
@@ -52,8 +52,8 @@ namespace updater {
inline std::ptrdiff_t m_pClippingWeapon = 0x1290; inline std::ptrdiff_t m_pClippingWeapon = 0x1290;
inline std::ptrdiff_t m_ArmorValue = 0x14F0; inline std::ptrdiff_t m_ArmorValue = 0x14F0;
inline std::ptrdiff_t m_iHealth = 0x32C; inline std::ptrdiff_t m_iHealth = 0x32C;
inline std::ptrdiff_t dwPlayerPawn = 0x7BC; inline std::ptrdiff_t m_hPlayerPawn = 0x7BC;
inline std::ptrdiff_t dwSanitizedName = 0x720; inline std::ptrdiff_t m_sSanitizedPlayerName = 0x720;
inline std::ptrdiff_t m_iTeamNum = 0x3BF; inline std::ptrdiff_t m_iTeamNum = 0x3BF;
inline std::ptrdiff_t m_vecOrigin = 0x1214; inline std::ptrdiff_t m_vecOrigin = 0x1214;
} }
+3 -3
View File
@@ -19,7 +19,7 @@ namespace hack {
const view_matrix_t view_matrix = process->read<view_matrix_t>(base_client.base + updater::offsets::dwViewMatrix); const view_matrix_t view_matrix = process->read<view_matrix_t>(base_client.base + updater::offsets::dwViewMatrix);
const uintptr_t entity_list = process->read<uintptr_t>(base_client.base + updater::offsets::dwEntityList); const uintptr_t entity_list = process->read<uintptr_t>(base_client.base + updater::offsets::dwEntityList);
const std::uint32_t localPlayerPawn = process->read<std::uint32_t>(localPlayer + updater::offsets::dwPlayerPawn); const std::uint32_t localPlayerPawn = process->read<std::uint32_t>(localPlayer + updater::offsets::m_hPlayerPawn);
if (!localPlayerPawn) if (!localPlayerPawn)
return; return;
const uintptr_t localList_entry2 = process->read<uintptr_t>(entity_list + 0x8 * ((localPlayerPawn & 0x7FFF) >> 9) + 16); const uintptr_t localList_entry2 = process->read<uintptr_t>(entity_list + 0x8 * ((localPlayerPawn & 0x7FFF) >> 9) + 16);
@@ -97,7 +97,7 @@ namespace hack {
continue; continue;
const std::uint32_t playerPawn = process->read<std::uint32_t>(player + updater::offsets::dwPlayerPawn); const std::uint32_t playerPawn = process->read<std::uint32_t>(player + updater::offsets::m_hPlayerPawn);
const uintptr_t list_entry2 = process->read<uintptr_t>(entity_list + 0x8 * ((playerPawn & 0x7FFF) >> 9) + 16); const uintptr_t list_entry2 = process->read<uintptr_t>(entity_list + 0x8 * ((playerPawn & 0x7FFF) >> 9) + 16);
if (!list_entry2) if (!list_entry2)
@@ -116,7 +116,7 @@ namespace hack {
continue; continue;
std::string playerName = "Invalid Name"; std::string playerName = "Invalid Name";
const DWORD64 playerNameAddress = process->read<DWORD64>(player + updater::offsets::dwSanitizedName); const DWORD64 playerNameAddress = process->read<DWORD64>(player + updater::offsets::m_sSanitizedPlayerName);
if (playerNameAddress) { if (playerNameAddress) {
char buf[256]; char buf[256];
+2 -2
View File
@@ -17,8 +17,8 @@
"m_pClippingWeapon": 4752, "m_pClippingWeapon": 4752,
"m_ArmorValue": 5360, "m_ArmorValue": 5360,
"m_iHealth": 812, "m_iHealth": 812,
"dwPlayerPawn": 1980, "m_hPlayerPawn": 1980,
"dwSanitizedName": 1824, "m_sSanitizedPlayerName": 1824,
"m_iTeamNum": 959, "m_iTeamNum": 959,
"m_vecOrigin": 4628 "m_vecOrigin": 4628
} }