Fix DW crash

This commit is contained in:
Federico Cecchetto 2022-06-05 00:20:11 +02:00
parent d2d26a8d91
commit c76e55cca7
2 changed files with 5 additions and 4 deletions

View File

@ -33,7 +33,7 @@ namespace branding
const auto font = game::R_RegisterFont("fonts/fira_mono_bold.ttf", 20);
if (font)
{
game::R_AddCmdDrawText(utils::string::va("H1-Mod: %s (%s %s)", VERSION, __DATE__, __TIME__), 0x7FFFFFFF, font, 10.f,
game::R_AddCmdDrawText("H1-Mod: " VERSION " (" __DATE__ " " __TIME__ ")", 0x7FFFFFFF, font, 10.f,
5.f + static_cast<float>(font->pixelHeight), 1.f, 1.f, 0.0f, color, 0);
}
}

View File

@ -593,8 +593,9 @@ namespace demonware
std::memcpy(reinterpret_cast<void*>(0x9EDB08_b), "http://%s:%d/auth/", sizeof("http://%s:%d/auth/"));
// utils::hook::set<uint8_t>(0x19F8C0_b, 0xC3); // SV_SendMatchData, not sure
utils::hook::nop(0x19BB67_b, 5); // LiveStorage_SendMatchDataComplete
utils::hook::nop(0x19BC3F_b, 5); // LiveStorage_GettingStoreConfigComplete probably
utils::hook::nop(0x19BB67_b, 5); // LiveStorage_SendMatchDataComplete (crashes at the end of match)
utils::hook::nop(0x19BC3F_b, 5); // LiveStorage_GettingStoreConfigComplete probably (crashes randomly)
utils::hook::nop(0x19BC48_b, 5); // similar to above (crashes in killcam)
utils::hook::set<uint8_t>(0x1A3340_b, 0xC3); // Live_CheckForFullDisconnect
// Remove some while loop that freezes the rendering for a few secs while connecting
@ -608,7 +609,7 @@ namespace demonware
utils::hook::set(0x47B2B0_b, 0xC301B0);
// xpartygo -> just start the match
utils::hook::jump(0x355B80_b, request_start_match_stub, true);
utils::hook::jump(0x355B80_b, request_start_match_stub);
utils::hook::set(0x396AD0_b, 0xC301B0); // DB_IsZoneLoaded("ffotd")
utils::hook::set(0x4DD600_b, 0xC300B0); // dont use ffotd