private IEnumerator MoveAndUpdateTurns(BattleFieldFigure figure, BattleFieldCell cell) { figure.BattleField.BattleController.DeactivateAllCells(); yield return(figure.MoveToAnotherCellWithAnimation(cell)); if (figure.GetRelevantMoves().Length > 0) { figure.BattleField.BattleController.ActivateAllCells(figure.GetRelevantMoves()); } else { figure.BattleField.BattleController.SwitchTurn(); } }
private IEnumerator FigureTurn(BattleFieldFigure figure, CellBase cell) { yield return(figure.MoveToAnotherCellWithAnimation(cell)); figure.LaunchAnAttack(); _controller.ActivateAllCells(figure.GetRelevantMoves()); if (_currentFreezeTime >= _freezeTime) { _delay = _maxDelay; _currentFreezeTime = 0; _freezing = false; IsActive = false; Destroy(_iceImageInstance); _controller.SwitchTurn(); } }
protected override void SkillAction(BattleFieldFigure figure, BattleFieldCell cell) { StartCoroutine(figure.MoveToAnotherCellWithAnimation(cell)); _controller.ActivateAllCells(figure.GetRelevantMoves()); }