mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-11-07 17:36:07 +00:00
Implement new logger (#1426)
* Implement multi-channel logger * Implement chat filter * Improve a bit * Improvement * Add debug message filter and filter mode * Avoid duplicate debug prefix string Co-authored-by: ORelio <ORelio@users.noreply.github.com>
This commit is contained in:
parent
939c8fb383
commit
38a890f840
9 changed files with 277 additions and 43 deletions
|
|
@ -704,7 +704,10 @@ namespace MinecraftClient
|
|||
/// <param name="text">Log text to write</param>
|
||||
protected void LogToConsole(object text)
|
||||
{
|
||||
ConsoleIO.WriteLogLine(String.Format("[{0}] {1}", this.GetType().Name, text));
|
||||
if (_handler == null || master == null)
|
||||
ConsoleIO.WriteLogLine(String.Format("[{0}] {1}", this.GetType().Name, text));
|
||||
else
|
||||
Handler.Log.Info(String.Format("[{0}] {1}", this.GetType().Name, text));
|
||||
string logfile = Settings.ExpandVars(Settings.chatbotLogFile);
|
||||
|
||||
if (!String.IsNullOrEmpty(logfile))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue