Log . Unity

MIT
by frarf

Small Unity logging library

( Crawled 19 minutes ago )
+

log.unity

log.unity is a super small C# logging library for Unity. Inspired by log.lua

Installation

Just drop the Log.cs file somewhere in your Unity project.

Usage

log.unity has 7 different logging methods, which are:
Log.Trace([str])
Log.Debug([str])
Log.Todo([str])
Log.Info([str])
Log.Warn([str])
Log.Error([str])
Log.Critical([str])

Each method can take in multiple strings, unlike Unity's default Debug.Log. Every string is seperated out by two spaces if you provide multiple strings.
Each log has a unique color, and provides useful information in the log, like the time in a HOUR:MINUTE:SECOND format, and the script that called the log method.

log.unity also provides a convenience method, Log.Print, which is similar to Unity's default Debug.Log, except it can take in multiple strings, like the rest of the Log methods.

log.unity can save the entire log into an out file, which is a directory leading to a plain text file. To enable this functionality, set the directory to Log.outFile. log.unity will log all previous logs if it was not enabled from the start.

Liscense

log.unity uses the MIT license. See LICENSE for more info.