From 8aa2b8400cf0df6cf0e94c1ffc4b3252da55d40f Mon Sep 17 00:00:00 2001 From: a2x <45197573+a2x@users.noreply.github.com> Date: Fri, 15 Dec 2023 01:23:32 +1000 Subject: [PATCH] Fix `dwForceAttack` and `dwForceAttack2` patterns --- config.json | 4 ++-- generated/offsets.cs | 6 +++--- generated/offsets.hpp | 6 +++--- generated/offsets.json | 4 ++-- generated/offsets.py | 6 +++--- generated/offsets.rs | 6 +++--- generated/offsets.yaml | 4 ++-- src/dumper/offsets.rs | 4 ++-- 8 files changed, 20 insertions(+), 20 deletions(-) diff --git a/config.json b/config.json index 47c8faf..b26779c 100644 --- a/config.json +++ b/config.json @@ -25,7 +25,7 @@ { "name": "dwForceAttack", "module": "client.dll", - "pattern": "48 8D 0D ? ? ? ? E9 44 42 B4 FF", + "pattern": "48 8D 0D ? ? ? ? E9 C4 42 B4 FF", "operations": [ { "type": "rip" @@ -39,7 +39,7 @@ { "name": "dwForceAttack2", "module": "client.dll", - "pattern": "48 8D 0D ? ? ? ? E9 54 42 B4 FF", + "pattern": "48 8D 0D ? ? ? ? E9 D4 42 B4 FF", "operations": [ { "type": "rip" diff --git a/generated/offsets.cs b/generated/offsets.cs index 706464a..62c6175 100644 --- a/generated/offsets.cs +++ b/generated/offsets.cs @@ -1,12 +1,12 @@ /* * Created using https://github.com/a2x/cs2-dumper - * Thu, 14 Dec 2023 11:58:28 +0000 + * Thu, 14 Dec 2023 15:21:21 +0000 */ public static class client_dll { // client.dll public const nint dwEntityList = 0x17C18E0; - public const nint dwForceAttack = 0x16C2190; - public const nint dwForceAttack2 = 0x16C2340; + public const nint dwForceAttack = 0x16C1E30; + public const nint dwForceAttack2 = 0x16C1EC0; public const nint dwForceBackward = 0x16C2100; public const nint dwForceCrouch = 0x16C23D0; public const nint dwForceForward = 0x16C2070; diff --git a/generated/offsets.hpp b/generated/offsets.hpp index 3ac46d5..655d942 100644 --- a/generated/offsets.hpp +++ b/generated/offsets.hpp @@ -1,6 +1,6 @@ /* * Created using https://github.com/a2x/cs2-dumper - * Thu, 14 Dec 2023 11:58:28 +0000 + * Thu, 14 Dec 2023 15:21:21 +0000 */ #pragma once @@ -9,8 +9,8 @@ namespace client_dll { // client.dll constexpr std::ptrdiff_t dwEntityList = 0x17C18E0; - constexpr std::ptrdiff_t dwForceAttack = 0x16C2190; - constexpr std::ptrdiff_t dwForceAttack2 = 0x16C2340; + constexpr std::ptrdiff_t dwForceAttack = 0x16C1E30; + constexpr std::ptrdiff_t dwForceAttack2 = 0x16C1EC0; constexpr std::ptrdiff_t dwForceBackward = 0x16C2100; constexpr std::ptrdiff_t dwForceCrouch = 0x16C23D0; constexpr std::ptrdiff_t dwForceForward = 0x16C2070; diff --git a/generated/offsets.json b/generated/offsets.json index c87fd58..2f961c1 100644 --- a/generated/offsets.json +++ b/generated/offsets.json @@ -6,11 +6,11 @@ "comment": null }, "dwForceAttack": { - "value": 23863696, + "value": 23862832, "comment": null }, "dwForceAttack2": { - "value": 23864128, + "value": 23862976, "comment": null }, "dwForceBackward": { diff --git a/generated/offsets.py b/generated/offsets.py index 6a911c4..27abf8a 100644 --- a/generated/offsets.py +++ b/generated/offsets.py @@ -1,12 +1,12 @@ ''' Created using https://github.com/a2x/cs2-dumper -Thu, 14 Dec 2023 11:58:28 +0000 +Thu, 14 Dec 2023 15:21:21 +0000 ''' class client_dll: # client.dll dwEntityList = 0x17C18E0 - dwForceAttack = 0x16C2190 - dwForceAttack2 = 0x16C2340 + dwForceAttack = 0x16C1E30 + dwForceAttack2 = 0x16C1EC0 dwForceBackward = 0x16C2100 dwForceCrouch = 0x16C23D0 dwForceForward = 0x16C2070 diff --git a/generated/offsets.rs b/generated/offsets.rs index b1d5575..ec6dc8d 100644 --- a/generated/offsets.rs +++ b/generated/offsets.rs @@ -1,14 +1,14 @@ /* * Created using https://github.com/a2x/cs2-dumper - * Thu, 14 Dec 2023 11:58:28 +0000 + * Thu, 14 Dec 2023 15:21:21 +0000 */ #![allow(non_snake_case, non_upper_case_globals)] pub mod client_dll { // client.dll pub const dwEntityList: usize = 0x17C18E0; - pub const dwForceAttack: usize = 0x16C2190; - pub const dwForceAttack2: usize = 0x16C2340; + pub const dwForceAttack: usize = 0x16C1E30; + pub const dwForceAttack2: usize = 0x16C1EC0; pub const dwForceBackward: usize = 0x16C2100; pub const dwForceCrouch: usize = 0x16C23D0; pub const dwForceForward: usize = 0x16C2070; diff --git a/generated/offsets.yaml b/generated/offsets.yaml index 2250f16..88ef28e 100644 --- a/generated/offsets.yaml +++ b/generated/offsets.yaml @@ -1,8 +1,8 @@ --- client_dll: # client.dll dwEntityList: 24910048 - dwForceAttack: 23863696 - dwForceAttack2: 23864128 + dwForceAttack: 23862832 + dwForceAttack2: 23862976 dwForceBackward: 23863552 dwForceCrouch: 23864272 dwForceForward: 23863408 diff --git a/src/dumper/offsets.rs b/src/dumper/offsets.rs index 917fbd8..22f05c3 100644 --- a/src/dumper/offsets.rs +++ b/src/dumper/offsets.rs @@ -235,7 +235,7 @@ mod tests { .expect("Failed to find client.dll") .base(); - const BUTTONS: [&str; 8] = [ + const FORCE_BUTTONS: [&str; 8] = [ "dwForceAttack", "dwForceAttack2", "dwForceBackward", @@ -257,7 +257,7 @@ mod tests { // Sleep for a second so we're able to test. sleep(Duration::from_secs(1)); - for button in &BUTTONS { + for button in &FORCE_BUTTONS { let offset = get_offset_value("client.dll", button) .expect(&format!("Failed to find {} offset", button));