private void OnDestroy() { MultiplayerSession.Close(); SceneManager.activeSceneChanged -= this.OnActiveSceneChanged; Logger.log?.Debug($"{name}: OnDestroy()"); instance = null; // This MonoBehaviour is being destroyed, so set the static instance property to null. }
public void OnApplicationQuit() { MultiplayerSession.Close(); _harmony.UnpatchAll("com.brian91292.beatsaber.cameraplus"); }