Closed Alivent closed 8 years ago
Currently the only logging levels are: Fatal Error Warn Info There should also a Debug and Trace log levels to track things while debugging the game.
and add to the log defines
You realise you can just open a pull request, right? I mean, you've basically written all the code.
Oh I didn't realize that! Sorry
Currently the only logging levels are: Fatal Error Warn Info There should also a Debug and Trace log levels to track things while debugging the game.
define SPARKY_LOG_LEVEL_FATAL 0
define SPARKY_LOG_LEVEL_ERROR 1
define SPARKY_LOG_LEVEL_WARN 2
define SPARKY_LOG_LEVEL_INFO 3
define SPARKY_LOG_LEVEL_DEBUG 4
define SPARKY_LOG_LEVEL_TRACE 5
and add to the log defines
if SPARKY_LOG_LEVEL >= SPARKY_LOG_LEVEL_DEBUG
define SP_DEBUG(...) sp::internal::log_message(SPARKY_LOG_LEVEL_DEBUG, true, "SPARKY: ", VA_ARGS)
define _SP_DEBUG(...) sp::internal::log_message(SPARKY_LOG_LEVEL_DEBUG, false, __VA_ARGS__)
else
define SP_DEBUG(...)
define _SP_DEBUG(...)
endif
if SPARKY_LOG_LEVEL >= SPARKY_LOG_LEVEL_TRACE
define SP_TRACE(...) sp::internal::log_message(SPARKY_LOG_LEVEL_TRACE, true, "SPARKY: ", VA_ARGS)
define _SP_TRACE(...) sp::internal::log_message(SPARKY_LOG_LEVEL_TRACE, false, __VA_ARGS__)
else
define SP_TRACE(...)
define _SP_TRACE(...)
endif