/// <summary> /// Unsubscribes to the pulse. /// </summary> protected void UnsubscribeToPulse() { if (_isSubscribed == false || _pulse == null) { return; } _pulse.UnsubscribeToPulse(this); _isSubscribed = false; }
protected override void OnDisable() { base.OnDisable(); if (_ParentPulse != null) { _ParentPulse.UnsubscribeToPulse(this); } #if UNITY_EDITOR if (Application.isPlaying == false) { EditorApplication.update -= Update; } #endif }