Replace MSVC __debugbreak with cross-compiler DEBUG_BREAK macro. (#1540)

This commit is contained in:
ModMaker101
2026-04-26 12:23:52 -05:00
committed by GitHub
parent 3ab29ec26e
commit 585455cef0
73 changed files with 117 additions and 129 deletions
+2 -5
View File
@@ -96,7 +96,7 @@ CMinecraftApp::CMinecraftApp()
// 4J Stu - See comment for GAME_SETTINGS_PROFILE_DATA_BYTES in Xbox_App.h
DebugPrintf("WARNING: The size of the profile GAME_SETTINGS struct has changed, so all stat data is likely incorrect. Is: %d, Should be: %d\n",sizeof(GAME_SETTINGS),GAME_SETTINGS_PROFILE_DATA_BYTES);
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
}
@@ -1300,9 +1300,6 @@ int CMinecraftApp::OldProfileVersionCallback(LPVOID pParam,unsigned char *pucDat
{
// This might be from a version during testing of new profile updates
app.DebugPrintf("Don't know what to do with this profile version!\n");
#ifndef _CONTENT_PACKAGE
// __debugbreak();
#endif
GAME_SETTINGS *pGameSettings=(GAME_SETTINGS *)pucData;
pGameSettings->ucMenuSensitivity=100; //eGameSetting_Sensitivity_InMenu
@@ -6421,7 +6418,7 @@ void CMinecraftApp::InitialiseTips()
{
// the m_TriviaTipA or the m_GameTipA are out of sync
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
}
}
+1 -2
View File
@@ -171,7 +171,7 @@ DLCPack *DLCManager::getPack(DWORD index, EDLCType type /*= e_DLCType_All*/)
if(index >= m_packs.size())
{
app.DebugPrintf("DLCManager: Trying to access a DLC pack beyond the range of valid packs\n");
__debugbreak();
DEBUG_BREAK();
}
pack = m_packs[index];
}
@@ -186,7 +186,6 @@ DWORD DLCManager::getPackIndex(DLCPack *pack, bool &found, EDLCType type /*= e_D
if(pack == nullptr)
{
app.DebugPrintf("DLCManager: Attempting to find the index for a nullptr pack\n");
//__debugbreak();
return foundIndex;
}
if( type != e_DLCType_All )
+2 -5
View File
@@ -107,7 +107,7 @@ void DLCPack::addChildPack(DLCPack *childPack)
#ifndef _CONTENT_PACKAGE
if(packId < 0 || packId > 15)
{
__debugbreak();
DEBUG_BREAK();
}
#endif
childPack->SetPackId( (packId<<24) | m_packId );
@@ -362,7 +362,7 @@ DWORD DLCPack::getFileIndexAt(DLCManager::EDLCType type, const wstring &path, bo
{
app.DebugPrintf("Unimplemented\n");
#ifndef __CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return 0;
}
@@ -392,9 +392,6 @@ bool DLCPack::hasPurchasedFile(DLCManager::EDLCType type, const wstring &path)
/*if(type == DLCManager::e_DLCType_All)
{
app.DebugPrintf("Unimplemented\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
#endif
return false;
}
#ifndef _CONTENT_PACKAGE
@@ -122,7 +122,7 @@ void ConsoleSchematicFile::load(DataInputStream *dis)
{
#ifndef _CONTENT_PACKAGE
app.DebugPrintf("ConsoleSchematicFile has read a nullptr tile entity\n");
__debugbreak();
DEBUG_BREAK();
#endif
}
else
@@ -635,7 +635,7 @@ void ConsoleSchematicFile::generateSchematicFile(DataOutputStream *dos, Level *l
}
#ifndef _CONTENT_PACKAGE
if(p!=blockCount) __debugbreak();
if(p!=blockCount) DEBUG_BREAK();
#endif
// We don't know how this will compress - just make a fixed length buffer to initially decompress into
@@ -24,7 +24,7 @@ GameRule::ValueType GameRule::getParameter(const wstring &parameterName)
{
#ifndef _CONTENT_PACKAGE
wprintf(L"WARNING: Parameter %ls was not set before being fetched\n", parameterName.c_str());
__debugbreak();
DEBUG_BREAK();
#endif
}
return m_parameters[parameterName];
@@ -238,7 +238,7 @@ HRESULT SonyLeaderboardManager::fillByIdsQuery(const SceNpId &myNpId, SceNpId* &
{
// 4J-JEV: Something terrible must have happend,
// 'getFriendslist' was supposed to be a synchronous operation.
__debugbreak();
DEBUG_BREAK();
// 4J-JEV: We can at least fall-back to just the players score.
len = 1;
@@ -247,8 +247,6 @@ void CPlatformNetworkManagerSony::HandlePlayerJoined(SQRNetworkPlayer *
void CPlatformNetworkManagerSony::HandlePlayerLeaving(SQRNetworkPlayer *pSQRPlayer)
{
//__debugbreak();
app.DebugPrintf( "Player 0x%p leaving.\n",
pSQRPlayer );
+17 -24
View File
@@ -320,7 +320,7 @@ void UIScene::loadMovie()
{
app.DebugPrintf("ERROR: Could not find any iggy movie for %ls!\n", moviePath.c_str());
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
app.FatalLoadError();
}
@@ -335,7 +335,7 @@ void UIScene::loadMovie()
{
app.DebugPrintf("ERROR: Failed to load iggy scene!\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
app.FatalLoadError();
}
@@ -941,9 +941,6 @@ void UIScene::_customDrawSlotControl(CustomDrawData *region, int iPad, shared_pt
// if(m_parentLayer == nullptr)
// {
// app.DebugPrintf("A scene is trying to navigate forwards, but it's parent layer is nullptr!\n");
//#ifndef _CONTENT_PACKAGE
// __debugbreak();
//#endif
// }
// else
// {
@@ -960,10 +957,6 @@ void UIScene::navigateBack()
if(m_parentLayer == nullptr)
{
// app.DebugPrintf("A scene is trying to navigate back, but it's parent layer is nullptr!\n");
#ifndef _CONTENT_PACKAGE
// __debugbreak();
#endif
}
else
{
@@ -1194,7 +1187,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handlePress did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1202,7 +1195,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Arguments for handlePress were not of the correct type\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1214,7 +1207,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handleFocusChange did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1222,7 +1215,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Arguments for handleFocusChange were not of the correct type\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1234,7 +1227,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handleInitFocus did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1242,7 +1235,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Arguments for handleInitFocus were not of the correct type\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1254,7 +1247,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handleCheckboxToggled did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1262,7 +1255,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Arguments for handleCheckboxToggled were not of the correct type\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1274,7 +1267,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handleSliderMove did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1282,7 +1275,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Arguments for handleSliderMove were not of the correct type\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1294,7 +1287,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handleAnimationEnd did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1306,7 +1299,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handleSelectionChanged did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1314,7 +1307,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Arguments for handleSelectionChanged were not of the correct type\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1332,7 +1325,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Callback for handleRequestMoreData did not have the correct number of arguments\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -1340,7 +1333,7 @@ void UIScene::externalCallback(IggyExternalFunctionCallUTF16 * call)
{
app.DebugPrintf("Arguments for handleRequestMoreData were not of the correct type\n");
#ifndef _CONTENT_PACKAGE
__debugbreak();
DEBUG_BREAK();
#endif
return;
}
@@ -390,7 +390,7 @@ void UIScene_MainMenu::handlePress(F64 controlId, F64 childId)
break;
#endif
default: __debugbreak();
default: DEBUG_BREAK();
}
bool confirmUser = false;