12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- using System.Runtime.CompilerServices;
- namespace BepInEx
- {
-
-
-
- public static class BepInLogger
- {
-
-
-
-
-
- public delegate void EntryLoggedEventHandler(string entry, bool show = false);
-
-
-
- public static event EntryLoggedEventHandler EntryLogged;
-
-
-
-
-
- public static void Log(string entry, bool show = false)
- {
- UnityEngine.UnityLogWriter.WriteStringToUnityLog($"BEPIN - {entry}\r\n");
- EntryLogged?.Invoke(entry, show);
- }
- }
- }
- namespace UnityEngine
- {
- internal sealed class UnityLogWriter
- {
- [MethodImpl(MethodImplOptions.InternalCall)]
- public static extern void WriteStringToUnityLog(string s);
- }
- }
|