HLE: Add a hook for JUTWarningConsole_f

JUTWarningConsole_f calls vprintf, but in a way we currently don't
handle (which messes up the printed message). However, it is a standard
debug print function, so we can directly hook it instead of waiting for
the vprintf call.

This is necessary to fix debug output in a few games now that vprintf
is properly detected in more games.
This commit is contained in:
Léo Lam 2016-12-04 16:16:27 +01:00
parent c785352c6f
commit 09fdab7fb4

View file

@ -52,6 +52,9 @@ static const SPatch OSPatches[] = {
// Debug/OS Support
{"OSPanic", HLE_OS::HLE_OSPanic, HLE_HOOK_REPLACE, HLE_TYPE_DEBUG},
// This needs to be put before vprintf (because vprintf is called indirectly by this)
{"JUTWarningConsole_f", HLE_OS::HLE_GeneralDebugPrint, HLE_HOOK_REPLACE, HLE_TYPE_DEBUG},
{"OSReport", HLE_OS::HLE_GeneralDebugPrint, HLE_HOOK_REPLACE, HLE_TYPE_DEBUG},
{"DEBUGPrint", HLE_OS::HLE_GeneralDebugPrint, HLE_HOOK_REPLACE, HLE_TYPE_DEBUG},
{"WUD_DEBUGPrint", HLE_OS::HLE_GeneralDebugPrint, HLE_HOOK_REPLACE, HLE_TYPE_DEBUG},