[General]: Cleanup usage of outputdebugstring (#733)
This commit is contained in:
parent
bd7d2fe059
commit
024440a55e
@ -134,7 +134,9 @@ namespace Components
|
||||
if (!MiniDumpWriteDump(GetCurrentProcess(), GetCurrentProcessId(), hFile, static_cast<MINIDUMP_TYPE>(MiniDumpType), &ex, nullptr, nullptr))
|
||||
{
|
||||
MessageBoxA(nullptr, Utils::String::Format("There was an error creating the minidump ({})! Hit OK to close the program.", Utils::GetLastWindowsError()), "ERROR", MB_OK | MB_ICONERROR);
|
||||
#ifdef _DEBUG
|
||||
OutputDebugStringA("Failed to create new minidump!");
|
||||
#endif
|
||||
Utils::OutputDebugLastError();
|
||||
TerminateProcess(GetCurrentProcess(), ExceptionInfo->ExceptionRecord->ExceptionCode);
|
||||
}
|
||||
|
@ -1979,11 +1979,6 @@ namespace Components
|
||||
//material->drawSurf[9] = material359.drawSurf[1];
|
||||
//material->drawSurf[10] = material359.drawSurf[2];
|
||||
//material->drawSurf[11] = material359.drawSurf[3];
|
||||
|
||||
if (material359.sGameFlags & 0x100)
|
||||
{
|
||||
//OutputDebugStringA("");
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
|
@ -16,7 +16,9 @@ namespace Steam
|
||||
|
||||
int RemoteStorage::FileRead(const char *pchFile, void *pvData, int cubDataToRead)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
OutputDebugStringA(pchFile);
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -156,24 +156,30 @@ namespace Steam
|
||||
template<typename T, typename... Args>
|
||||
T invoke(const std::string& methodName, Args... args)
|
||||
{
|
||||
if(!this->interfacePtr)
|
||||
if (!this->interfacePtr)
|
||||
{
|
||||
OutputDebugStringA(::Utils::String::VA("Steam interface pointer is invalid (%s)!\n", methodName.data()));
|
||||
#ifdef _DEBUG
|
||||
OutputDebugStringA(::Utils::String::Format("Steam interface pointer is invalid '{}'!\n", methodName));
|
||||
#endif
|
||||
return T();
|
||||
}
|
||||
|
||||
auto method = this->getMethod(methodName);
|
||||
if (!method.first)
|
||||
{
|
||||
OutputDebugStringA(::Utils::String::VA("Steam interface method %s not found!\n", methodName.data()));
|
||||
#ifdef _DEBUG
|
||||
OutputDebugStringA(::Utils::String::Format("Steam interface method '{}' not found!\n", methodName));
|
||||
#endif
|
||||
return T();
|
||||
}
|
||||
|
||||
std::size_t argc = method.second;
|
||||
constexpr std::size_t passedArgc = Interface::AddSizes<sizeof(Args)...>::value;
|
||||
if(passedArgc != argc)
|
||||
if (passedArgc != argc)
|
||||
{
|
||||
OutputDebugStringA(::Utils::String::VA("Steam interface arguments for method %s do not match (expected %d bytes, but got %d bytes)!\n", methodName.data(), argc, passedArgc));
|
||||
#ifdef _DEBUG
|
||||
OutputDebugStringA(::Utils::String::Format("Steam interface arguments for method '{}' do not match (expected {} bytes, but got {} bytes)!\n", methodName, argc, passedArgc));
|
||||
#endif
|
||||
return T();
|
||||
}
|
||||
|
||||
|
@ -123,7 +123,9 @@ namespace Steam
|
||||
|
||||
if (!Proxy::Inititalize())
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
OutputDebugStringA("Steam proxy not initialized properly");
|
||||
#endif
|
||||
Components::StartupMessages::AddMessage("Warning:\nUnable to connect to Steam. Steam features will be unavailable");
|
||||
}
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user