Add new debug log category for saving whatever was sent to console.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9102 4a71c877-e1ca-e34f-864e-861f7616d084master
parent
357de2a6cb
commit
93f1d85e2d
|
@ -78,6 +78,7 @@ static const char *code_part_names[] = {
|
|||
"fatal",
|
||||
"input",
|
||||
"popup",
|
||||
"console",
|
||||
"last"
|
||||
};
|
||||
|
||||
|
|
|
@ -168,6 +168,7 @@ typedef enum {
|
|||
LOG_FATAL, /**< special; on by default, for both debug & release builds */
|
||||
LOG_INPUT, // mouse / keyboard events
|
||||
LOG_POPUP, // special, on by default, for both debug & release builds (used for OS dependent popup code)
|
||||
LOG_CONSOLE, // send console messages to file
|
||||
LOG_LAST /**< _must_ be last! */
|
||||
} code_part;
|
||||
|
||||
|
|
|
@ -236,6 +236,8 @@ static BOOL _addConsoleMessage(const char *messageText, CONSOLE_TEXT_JUSTIFICATI
|
|||
jusType = defJustification;
|
||||
}
|
||||
|
||||
debug(LOG_CONSOLE, "(to player %d): %s", (int)player, messageText);
|
||||
|
||||
consoleStorage[messageIndex].player = player;
|
||||
|
||||
/* Precalculate and store (quicker!) the indent for justified text */
|
||||
|
|
Loading…
Reference in New Issue