public void ActivateFigurePostTurnLogic(IFigureEntity figureEntity) { foreach (var figurePostTurnLogic in figureEntity.Def.FigurePostTurnLogics) { var isActivated = figurePostTurnLogic.ActivatePostTurnLogic(figureEntity); if (isActivated) { return; } } SwitcherTurn.SwitchTurn(true, true); }
private void RandomMoveFocusCell() { var cells = new List <IBoardCell>(); foreach (var cell in BoardModel.Cells) { if (cell.Status == BoardCellStatus.AvailableForMove) { cells.Add(cell); } } if (!cells.IsEmpty()) { GameMaster.MoveFocusFigure(cells.GetRandom()); return; } Debug.LogWarning("Can't find available cells"); GameSwitcherTurn.SwitchTurn(true, true); }
protected void SwitchTurn(bool switchTeam, bool needPrepareControl) { SwitcherTurn.SwitchTurn(switchTeam, needPrepareControl); }