diff --git a/src/client/component/dedicated.cpp b/src/client/component/dedicated.cpp index 08222477..46f5f402 100644 --- a/src/client/component/dedicated.cpp +++ b/src/client/component/dedicated.cpp @@ -177,17 +177,6 @@ namespace dedicated ui_set_active_menu_hook.invoke(a1, a2); } - - utils::hook::detour sub_552830_hook; - void* sub_552830_stub() - { - // sub_554D00 svs_clients along with other svs stuff - // Upon loading a 2nd map (ex. doing map mp_bog; map mp_crash) sub_552830 is called instead of sub_554D00 - // But svs stuff is already deallocated so it will read bad memory -> crash - // Calling sub_554D00 makes sure it reallocates that stuff first - utils::hook::invoke(0x554D00_b); - return sub_552830_hook.invoke(); - } } void initialize() @@ -327,7 +316,8 @@ namespace dedicated // Workaround for server spamming 'exec default_xboxlive.cfg' when not running ui_set_active_menu_hook.create(0x1E4D80_b, ui_set_active_menu_stub); - sub_552830_hook.create(0x552830_b, sub_552830_stub); + // Dont free server client memory on asset loading + utils::hook::nop(0x132474_b, 5); // initialize the game after onlinedataflags is 32 (workaround) scheduler::schedule([=]()