public void Retrieve() { if (_stun) { if (_animationManager._ended) { _animationManager.Stop(); if (isMain) { Communicator.SendEndofStun(); } _idle = true; _stun = false; _attack1 = false; _attack2 = false; _hurt = false; if (_animationManager._animation.AnimationId == 15 || _animationManager._animation.AnimationId == 14 && isMain) { _enable = false; Game1.pnlDefeat.IsHidden = false; healthBar.IsHidden = true; nickName.IsHidden = true; Communicator.SendExit(); } bools[2] = false; bools[1] = false; } } if (!_air) { Velocity.Y = 0; } }
protected override void OnExiting(Object sender, EventArgs args) { base.OnExiting(sender, args); Communicator.SendExit(); }