diff --git a/Runtimes/Unity/BepInEx.Unity.IL2CPP/Logging/IL2CPPUnityLogSource.cs b/Runtimes/Unity/BepInEx.Unity.IL2CPP/Logging/IL2CPPUnityLogSource.cs index 53e0d6b..8896e80 100644 --- a/Runtimes/Unity/BepInEx.Unity.IL2CPP/Logging/IL2CPPUnityLogSource.cs +++ b/Runtimes/Unity/BepInEx.Unity.IL2CPP/Logging/IL2CPPUnityLogSource.cs @@ -32,6 +32,9 @@ public class IL2CPPUnityLogSource : ILogSource LogType.Exception => LogLevel.Error, _ => LogLevel.Message }; + if (type is LogType.Exception or LogType.Error && !string.IsNullOrEmpty(exception)) + logLine += $"\nStack trace:\n{exception}"; + LogEvent?.Invoke(this, new LogEventArgs(logLine, level, this)); }