/// <summary> /// Unity OnDestroy method /// </summary> private void OnDestroy() { SetCollisionBetweenSimulationObjects(true); StopConnection(); PacketsProcessor.RemoveSubscription <Commands.Run>(); PacketsProcessor.RemoveSubscription <Commands.Stop>(); PacketsProcessor.RemoveSubscription <Commands.EnvironmentState>(); PacketsProcessor.RemoveSubscription <Commands.Ping>(); }