blob: 0f40cd25ff055b0d8963f45bfc5df7eaf49bbba0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
using System;
namespace StardewModdingAPI
{
/// <summary>
/// A struct to store the message and the Date and Time the log entry was created
/// </summary>
public struct LogInfo
{
public string Message { get; set; }
public string LogTime { get; set; }
public string LogDate { get; set; }
public ConsoleColor Colour { get; set; }
public LogInfo(string message, ConsoleColor colour = ConsoleColor.Gray)
{
if (string.IsNullOrEmpty(message))
message = "[null]";
Message = message;
LogDate = DateTime.Now.ToString("yyyy-MM-dd");
LogTime = DateTime.Now.ToString("hh:mm:ss.fff tt");
Colour = colour;
}
}
}
|