diff --git a/TSTSSESHangar/Data/Scripts/FactionHangar/Session.cs b/TSTSSESHangar/Data/Scripts/FactionHangar/Session.cs index 37b3ace..6cc071d 100644 --- a/TSTSSESHangar/Data/Scripts/FactionHangar/Session.cs +++ b/TSTSSESHangar/Data/Scripts/FactionHangar/Session.cs @@ -2350,6 +2350,11 @@ protected override void UnloadData() { } } + // Add this unhook + if (!isDedicated) { + MyVisualScriptLogicProvider.ToolEquipped -= ToolEquipped; + } + if (MyAPIGateway.Utilities != null) { MyAPIGateway.Utilities.MessageEntered -= ChatHandler; } @@ -2358,10 +2363,6 @@ protected override void UnloadData() { MyAPIGateway.Multiplayer.UnregisterMessageHandler(NetworkHandle, Comms.MessageHandler); } - //if (!isDedicated) { - // Sandbox.ModAPI.MyAPIGateway.Utilities.ShowMessage("FactionHangar", "Mod Unloaded"); - //} - Instance = null; } catch (Exception ex) {