From 8c940fcbc88e9e450c8b9c0f06a9b717f53aea9c Mon Sep 17 00:00:00 2001 From: Amos <48657826+Mauler125@users.noreply.github.com> Date: Wed, 23 Feb 2022 21:03:06 +0100 Subject: [PATCH] Completely strip Miles SDK from dedicated --- r5dev/common/opcodes.cpp | 5 +++-- r5dev/core/stdafx.h | 6 +++--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/r5dev/common/opcodes.cpp b/r5dev/common/opcodes.cpp index 5256f83b..b56f3a04 100644 --- a/r5dev/common/opcodes.cpp +++ b/r5dev/common/opcodes.cpp @@ -259,8 +259,9 @@ void Dedicated_Init() // RUNTIME: GL_SCREEN //------------------------------------------------------------------------- { - SCR_BeginLoadingPlaque.Offset(0x82).Patch({ 0x90, 0x90, 0x90, 0x90, 0x90, 0x90 }); // JNE --> JMP | virtual call to 'CHLClient::CHudMessage'. - SCR_BeginLoadingPlaque.Offset(0xA4).Patch({ 0x90, 0x90, 0x90, 0x90, 0x90, 0x90 }); // JNE --> JMP | virtual call to 'CEngineVGui::OnLevelLoadingStarted'. + SCR_BeginLoadingPlaque.Offset(0x5B).Patch({ 0x90, 0x90, 0x90, 0x90, 0x90, 0x90 }); // CAL --> NOP | virtual call to 'CHLClient::MilesQueueEvent'. + SCR_BeginLoadingPlaque.Offset(0x82).Patch({ 0x90, 0x90, 0x90, 0x90, 0x90, 0x90 }); // CAL --> NOP | virtual call to 'CHLClient::CHudMessage'. + SCR_BeginLoadingPlaque.Offset(0xA4).Patch({ 0x90, 0x90, 0x90, 0x90, 0x90, 0x90 }); // CAL --> NOP | virtual call to 'CEngineVGui::OnLevelLoadingStarted'. SCR_BeginLoadingPlaque.Offset(0x1D6).Patch({ 0xEB, 0x27 }); // JNE --> JMP | Prevent connect command from crashing by invalid call to UI function. } diff --git a/r5dev/core/stdafx.h b/r5dev/core/stdafx.h index 894b1a1f..d688355d 100644 --- a/r5dev/core/stdafx.h +++ b/r5dev/core/stdafx.h @@ -66,12 +66,12 @@ namespace { #if !defined (DEDICATED) MODULE g_mGameDll = MODULE("r5apex.exe"); -#else // No DX imports. - MODULE g_mGameDll = MODULE("r5apex_ds.exe"); -#endif // !DEDICATED MODULE g_mRadVideoToolsDll = MODULE("bink2w64.dll"); MODULE g_mRadAudioDecoderDll = MODULE("binkawin64.dll"); MODULE g_mRadAudioSystemDll = MODULE("mileswin64.dll"); +#else // No DirectX and Miles imports. + MODULE g_mGameDll = MODULE("r5apex_ds.exe"); +#endif // !DEDICATED } #define MEMBER_AT_OFFSET(varType, varName, offset) \