Add debug break hook for Lua

ryzomclassic-develop
kaetemi 4 years ago
parent ae876e481a
commit d2900df0f6

@ -132,6 +132,11 @@ end
-- INIT --
----------
if debugBreak == nil then
-- replace this at runtime with the debugger break functions
debugBreak = function()
end
end
-- replace the assert function with a more verbose one
if oldAssert == nil then
@ -142,7 +147,8 @@ function assert(cond)
if not cond then
-- rawDebugInfo(colorTag(255, 0, 255) .. "ASSERTION FAILED !! ")
rawDebugInfo("@{FOFF}ASSERTION FAILED !! ")
dumpCallStack(2);
dumpCallStack(2)
debugBreak()
error("")
end
end

Loading…
Cancel
Save