Logging messages

Logging can be a useful way to debug issues during development, or notify the user that an error occurred. In bs::f it is handled though the Debug class. Use gDebug() for an easy way to access the Debug instance.

Use any of these methods to log a new message:

UINT32 x = 5;
gDebug().logDebug("Value of x is: " + toString(x));
if(x != 5)
gDebug().logError("X must equal 5!");

All logged messages will be output to the standard console output, as well as the attached debugger output (if any).

Messages are also saved internally, and can be output to a .html file by calling Debug::saveLog().

gDebug().saveLog("C:\myLog.html");