Setup

The following section briefly describes how to import, set up, and use the Thread-Safe Logger package in your Unity project. You can also download the offline version of this documentation in a PDF format (included in the package).

For more detailed setup information, including advanced settings and custom logging behavior, please refer to the offline version of this documentation.

Firstly, import the package in your project like any other package on the Unity Asset Store – go to Window\Package Manager, select My Assets as the package source, and import the Thread-Safe Logger package.

Then, add the main component located at Project GAMEDEV\Tools\Logger\Prefabs to your starting scene. Once added to an active scene, the object will stay alive across all scenes for the duration of the application. If there are multiple starting scenes, add the main component to all of them. The important thing is that the component is included in the scene that is started first. Without the main component, the Logger will function just fine; however, buffered log messages may not be always written to a log file on application exit, resulting in lost log messages on application exit.

That's it! You are now ready to use the full logging functionality as shown in the offline documentation.

In case you are using assembly definition files for your scripts, add the Thread-Safe Logger assembly located at Project GAMEDEV\Tools\Logger\Scripts as an assembly definition reference to your assembly files.
Do this for all assemblies containing scripts that need to use the ProjectGamedev.Logging namespace.

For further information and examples beyond the basic setup outlined above, please consult the offline documentation, or visit the API page.