The issue was that if you leave from the game to the main menu NetworkServer.active is false when onRunDestroyGlobal is executed. So, I've changed a check to remove hooks if they are applied.
Though, unsubscribing from hooks even if you not subscribed will not throw an error and work just fine. But that's up to you if you want remove that check completely.
The issue was that if you leave from the game to the main menu
NetworkServer.active
is false whenonRunDestroyGlobal
is executed. So, I've changed a check to remove hooks if they are applied.Though, unsubscribing from hooks even if you not subscribed will not throw an error and work just fine. But that's up to you if you want remove that check completely.