Logger
Fin Christensen edited this page May 2, 2015
·
1 revision
namespace FreezingArcher.Output
The logger is used for logging messages to the console and to a logfile located in the output directory. You may not use
Console.Write...
for command line output. Instead use the logger as the logger is aware of log levels and writes the
output to a file. Additionally the logger runs in an extra thread. Therefore the game performance is not affected when
producing a high amount of log lines. To add a log line do something like this:
Logger.Log.AddLogEntry (LogLevel.Debug, "AwesomeModule",
"The awesome module has reached an awesomeness of {0}!",
awesomeness);
- Debug: Messages for debug usage
- Fine: Totally unneccessary status information
- Info: Standard log level
- Warning: Just a warning, will not cause any crashes
- Error: Error which may cause a crash
- Severe: Severe error which will likely cause a crash
- Fatal: Fatal error may be logged immediately before a crash
- Crash: There was an error which the program couldn't handle and the game crashed
It is possible to set the log level of the logger via Logger.Log.SetLogLevel (LogLevel level)
. However you may use the
command line or the config file to set the log level. Otherwise those mechanism won't have any effect on the log level
any more.
- Application
- Renderer
- Physics
-
Sound
- [[Loading a
Sound
and creating aSource
|Sound#loading-a-Sound-and-creating-a-Source]]
- [[Loading a
- Input Management
- Update Management
- Data Structures
- Localization
- Messaging System
- Logger
- Command Line Interface
- Config File
- Object Recycling
- Dynamic Class Building
- Job Executer