diff options
author | Tom Barham <me@cpdt.dev> | 2022-01-06 14:26:37 +1000 |
---|---|---|
committer | Tom Barham <me@cpdt.dev> | 2022-01-06 14:26:37 +1000 |
commit | 98d89695eb6732979bd9c1e6e50a510394346891 (patch) | |
tree | 45d82c48fa4029a65ba509da0682009908dab523 /NorthstarDedicatedTest | |
parent | 733bf92983fa60abfaad6af5c0b9950c3d1e3a4e (diff) | |
download | NorthstarLauncher-98d89695eb6732979bd9c1e6e50a510394346891.tar.gz NorthstarLauncher-98d89695eb6732979bd9c1e6e50a510394346891.zip |
don't hook language functions on dedicated server
Diffstat (limited to 'NorthstarDedicatedTest')
-rw-r--r-- | NorthstarDedicatedTest/languagehooks.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/NorthstarDedicatedTest/languagehooks.cpp b/NorthstarDedicatedTest/languagehooks.cpp index 08bacaf9..0929b73d 100644 --- a/NorthstarDedicatedTest/languagehooks.cpp +++ b/NorthstarDedicatedTest/languagehooks.cpp @@ -1,6 +1,7 @@ #include "pch.h" #include "languagehooks.h" #include "gameutils.h" +#include "dedicated.h" #include <filesystem> #include <regex> @@ -104,6 +105,9 @@ char* GetGameLanguageHook() void InitialiseTier0LanguageHooks(HMODULE baseAddress) { + if (IsDedicated()) + return; + HookEnabler hook; ENABLER_CREATEHOOK(hook, (char*)baseAddress + 0xF560, &GetGameLanguageHook, reinterpret_cast<LPVOID*>(&GetGameLanguageOriginal)); }
\ No newline at end of file |