From 1800795a81a9e18b93af6ec465fe7a232625e5ff Mon Sep 17 00:00:00 2001 From: Raicuparta Date: Sat, 13 Nov 2021 19:31:09 +0100 Subject: [PATCH] Use OWML logs --- NomaiVR/Loaders/NomaiVRLoaderOWML.cs | 2 +- NomaiVR/Logs.cs | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/NomaiVR/Loaders/NomaiVRLoaderOWML.cs b/NomaiVR/Loaders/NomaiVRLoaderOWML.cs index 898bd88..9013fa1 100644 --- a/NomaiVR/Loaders/NomaiVRLoaderOWML.cs +++ b/NomaiVR/Loaders/NomaiVRLoaderOWML.cs @@ -7,7 +7,7 @@ namespace NomaiVR.Loaders { public class NomaiVRLoaderOwml : ModBehaviour { - private IModHelper Helper { get; set; } + public static IModHelper Helper { get; private set; } internal void Start() { NomaiVR.HarmonyInstance = new OwmlHarmonyInstance(ModHelper); diff --git a/NomaiVR/Logs.cs b/NomaiVR/Logs.cs index 0cacc35..762dcdc 100644 --- a/NomaiVR/Logs.cs +++ b/NomaiVR/Logs.cs @@ -1,4 +1,5 @@ -using NomaiVR.ModConfig; +using NomaiVR.Loaders; +using NomaiVR.ModConfig; namespace NomaiVR { @@ -19,15 +20,15 @@ namespace NomaiVR switch (messageType) { case MessageType.Error: - UnityEngine.Debug.LogError(message); + NomaiVRLoaderOwml.Helper.Console.WriteLine(message, OWML.Common.MessageType.Error); break; case MessageType.Warning: - UnityEngine.Debug.LogWarning(message); + NomaiVRLoaderOwml.Helper.Console.WriteLine(message, OWML.Common.MessageType.Warning); break; default: - UnityEngine.Debug.Log(message); + NomaiVRLoaderOwml.Helper.Console.WriteLine(message, OWML.Common.MessageType.Info); break; } }