diff --git a/NewHorizons/Main.cs b/NewHorizons/Main.cs index d4bcc7fc..f4c9ad09 100644 --- a/NewHorizons/Main.cs +++ b/NewHorizons/Main.cs @@ -158,7 +158,14 @@ namespace NewHorizons private static void OnWakeUp() { IsSystemReady = true; - Instance.OnStarSystemLoaded?.Invoke(Instance.CurrentStarSystem); + try + { + Instance.OnStarSystemLoaded?.Invoke(Instance.CurrentStarSystem); + } + catch (Exception e) + { + Logger.LogError($"Exception thrown when invoking star system loaded event with parameter [{Instance.CurrentStarSystem}] : {e.GetType().FullName} {e.Message} {e.StackTrace}"); + } } private void OnSceneUnloaded(Scene scene)