This commit is contained in:
watrabi
2025-09-18 17:55:52 -04:00
commit 977f1ff4b8
15030 changed files with 17324420 additions and 0 deletions
+49
View File
@@ -0,0 +1,49 @@
/* Copyright 2003-2005 ROBLOX Corporation, All Rights Reserved */
#include "rbx/Debug.h"
#include "RbxAssert.h"
#include "RbxFormat.h"
#include <algorithm>
const int CRASHONASSERT = 255;
void ReleaseAssert(int channel, const char* msg) {
if(channel == CRASHONASSERT)
RBXCRASH(msg);
else
FLog::FastLog(channel, msg, 0);
}
namespace RBX
{
// overload this in the debugger to pass by the crash
volatile bool Debugable::doCrashEnabled = true;
void Debugable::doCrash()
{
if(doCrashEnabled)
{
DebugBreak();
}
}
#pragma optimize ("", off )
void Debugable::doCrash(const char* message)
{
#if defined(RBX_PLATFORM_DURANGO)
OutputDebugStringA("ASSERTION FAILED: ");
OutputDebugStringA(message);
OutputDebugStringA("\n");
if (!IsDebuggerPresent())
return;
#endif
if (doCrashEnabled)
{
DebugBreak();
}
}
#pragma optimize ("", on )
} // rbx namespace