Commit 56e9787b authored by mercury233's avatar mercury233

update log

parent 0c980e1b
......@@ -253,7 +253,7 @@ namespace WindBot.Game
extra = packet.ReadInt16();
_duel.Fields[GetLocalPlayer(1)].Init(deck, extra);
Logger.WriteLine("Duel started: " + _room.Names[0] + " versus " + _room.Names[1]);
Logger.DebugWriteLine("Duel started: " + _room.Names[0] + " versus " + _room.Names[1]);
_ai.OnStart();
}
......@@ -263,7 +263,7 @@ namespace WindBot.Game
string otherName = _room.Position == 0 ? _room.Names[1] : _room.Names[0];
string textResult = (result == 2 ? "Draw" : result == 0 ? "Win" : "Lose");
Logger.WriteLine("Duel finished against " + otherName + ", result: " + textResult);
Logger.DebugWriteLine("Duel finished against " + otherName + ", result: " + textResult);
}
private void OnDraw(BinaryReader packet)
......
......@@ -6,16 +6,16 @@ namespace WindBot
{
public static void WriteLine(string message)
{
Console.WriteLine("[" + DateTime.Now.ToString("HH:mm:ss") + "] " + message);
Console.WriteLine("[" + DateTime.Now.ToString("yy-MM-dd HH:mm:ss") + "] " + message);
}
public static void DebugWriteLine(string message)
{
if (Program.DebugMode)
Console.WriteLine("[" + DateTime.Now.ToString("HH:mm:ss") + "] " + message);
Console.WriteLine("[" + DateTime.Now.ToString("yy-MM-dd HH:mm:ss") + "] " + message);
}
public static void WriteErrorLine(string message)
{
Console.Error.WriteLine("[" + DateTime.Now.ToString("HH:mm:ss") + "] " + message);
Console.Error.WriteLine("[" + DateTime.Now.ToString("yy-MM-dd HH:mm:ss") + "] " + message);
}
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment