From 58f5cd944cb387c6c46929dac6b665b740af21c4 Mon Sep 17 00:00:00 2001 From: Sepalani Date: Tue, 4 Oct 2016 21:40:43 +0100 Subject: [PATCH] HLE: Another DebugPrint case added --- Source/Core/Core/HLE/HLE_OS.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Source/Core/Core/HLE/HLE_OS.cpp b/Source/Core/Core/HLE/HLE_OS.cpp index 49da2e92e2..d181971e9d 100644 --- a/Source/Core/Core/HLE/HLE_OS.cpp +++ b/Source/Core/Core/HLE/HLE_OS.cpp @@ -32,12 +32,23 @@ void HLE_GeneralDebugPrint() { std::string report_message; + // Is gpr3 pointing to a pointer rather than an ASCII string if (PowerPC::HostRead_U32(GPR(3)) > 0x80000000) { - report_message = GetStringVA(4); + if (GPR(4) > 0x80000000) + { + // ___blank(void* this, const char* fmt, ...); + report_message = GetStringVA(4); + } + else + { + // ___blank(void* this, int log_type, const char* fmt, ...); + report_message = GetStringVA(5); + } } else { + // ___blank(const char* fmt, ...); report_message = GetStringVA(); }