Files
Blocks3D/src/source/ErrorFunctions.cpp
Modnark 415ea71664 Clean bloat comments
Please make sure these were bloat and not important.
2022-10-08 21:05:09 -04:00

27 lines
626 B
C++

#include <sstream>
#include "ErrorFunctions.h"
#include "Globals.h"
void OnError(int err, std::string msg)
{
std::string emsg = "An unexpected error has occured and "+g_appName+" has to quit. We're sorry!" + msg;
std::string title = g_appName+" Crash";
MessageBox(NULL, emsg.c_str(), title.c_str(), MB_OK);
exit(err);
}
void MessageBoxStr(std::string msg)
{
std::string title = g_appName;
MessageBox(NULL, msg.c_str(), title.c_str(), MB_OK);
}
void MessageBoxStream(std::stringstream msg)
{
std::string strMsg = msg.str();
std::string title = g_appName;
MessageBox(NULL, strMsg.c_str(), title.c_str(), MB_OK);
}