-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Rcmcpe
committed
May 10, 2020
1 parent
54c8f4f
commit 1f7f4fe
Showing
9 changed files
with
142 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
using System; | ||
using System.Drawing; | ||
using Console = Colorful.Console; | ||
|
||
namespace REVUnit.AutoArknights.Core | ||
{ | ||
public static class Log | ||
{ | ||
private static void WriteTime() | ||
{ | ||
Console.Write($"[{DateTime.Now:HH:mm:ss}] ", Color.Gray); | ||
} | ||
|
||
public static void Info(string message, bool withTime = false) | ||
{ | ||
if (withTime) WriteTime(); | ||
Console.Write("[Info]: ", Color.Gray); | ||
Console.WriteLine(message); | ||
} | ||
|
||
public static void InfoAlt(string message, bool withTime = false) | ||
{ | ||
if (withTime) WriteTime(); | ||
Console.Write("[Info]: ", Color.Yellow); | ||
Console.WriteLine(message); | ||
} | ||
|
||
public static void Warning(string message, bool withTime = false) | ||
{ | ||
if (withTime) WriteTime(); | ||
Console.Write("[Warn]: ", Color.Yellow); | ||
Console.WriteLine(message); | ||
} | ||
|
||
public static void Error(string message, bool withTime = false) | ||
{ | ||
if (withTime) WriteTime(); | ||
Console.Write("[ERROR]: ", Color.Red); | ||
Console.WriteLine(message); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters