aboutsummaryrefslogtreecommitdiff
path: root/NorthstarDedicatedTest/miscclientfixes.cpp
diff options
context:
space:
mode:
authorNorthstar <northstar@northstar.tf>2022-02-03 22:09:08 -0300
committerBarichello <artur@barichello.me>2022-02-03 22:09:08 -0300
commit75bf194b2fca06de805a7bc025c6dd8379250fa5 (patch)
treec9327ac7921ae80bb2d91381bb7db11b47ca2403 /NorthstarDedicatedTest/miscclientfixes.cpp
parente9f93ba2e8b9df280aed20131a1606d731d2dbbe (diff)
downloadNorthstarLauncher-75bf194b2fca06de805a7bc025c6dd8379250fa5.tar.gz
NorthstarLauncher-75bf194b2fca06de805a7bc025c6dd8379250fa5.zip
Format project
Diffstat (limited to 'NorthstarDedicatedTest/miscclientfixes.cpp')
-rw-r--r--NorthstarDedicatedTest/miscclientfixes.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/NorthstarDedicatedTest/miscclientfixes.cpp b/NorthstarDedicatedTest/miscclientfixes.cpp
index dc68d18c..62ffd4a4 100644
--- a/NorthstarDedicatedTest/miscclientfixes.cpp
+++ b/NorthstarDedicatedTest/miscclientfixes.cpp
@@ -3,7 +3,7 @@
#include "hookutils.h"
#include "dedicated.h"
-typedef void*(*CrashingWeaponActivityFuncType)(void* a1);
+typedef void* (*CrashingWeaponActivityFuncType)(void* a1);
CrashingWeaponActivityFuncType CrashingWeaponActivityFunc0;
CrashingWeaponActivityFuncType CrashingWeaponActivityFunc1;
@@ -32,11 +32,14 @@ void InitialiseMiscClientFixes(HMODULE baseAddress)
HookEnabler hook;
- // these functions will occasionally pass a null pointer on respawn, unsure what causes this but seems easiest just to return null if null, which seems to work fine
- // fucking sucks this has to be fixed like this but unsure what exactly causes this serverside, breaks vanilla compatibility to a degree tho
- // will say i have about 0 clue what exactly these functions do, testing this it doesn't even seem like they do much of anything i can see tbh
- ENABLER_CREATEHOOK(hook, (char*)baseAddress + 0x5A92D0, &CrashingWeaponActivityFunc0Hook, reinterpret_cast<LPVOID*>(&CrashingWeaponActivityFunc0));
- ENABLER_CREATEHOOK(hook, (char*)baseAddress + 0x5A9310, &CrashingWeaponActivityFunc1Hook, reinterpret_cast<LPVOID*>(&CrashingWeaponActivityFunc1));
+ // these functions will occasionally pass a null pointer on respawn, unsure what causes this but seems easiest just to return null if
+ // null, which seems to work fine fucking sucks this has to be fixed like this but unsure what exactly causes this serverside, breaks
+ // vanilla compatibility to a degree tho will say i have about 0 clue what exactly these functions do, testing this it doesn't even seem
+ // like they do much of anything i can see tbh
+ ENABLER_CREATEHOOK(
+ hook, (char*)baseAddress + 0x5A92D0, &CrashingWeaponActivityFunc0Hook, reinterpret_cast<LPVOID*>(&CrashingWeaponActivityFunc0));
+ ENABLER_CREATEHOOK(
+ hook, (char*)baseAddress + 0x5A9310, &CrashingWeaponActivityFunc1Hook, reinterpret_cast<LPVOID*>(&CrashingWeaponActivityFunc1));
// experimental: allow cl_extrapolate to be enabled without cheats
{