/// <summary> /// Set current state to the end of turn state /// </summary> void EnterStateEndOfTurn() { currentPhaseStateMethod = new CurrentPhaseState(StateEndOfTurn); CurrentlySelectedUnit.EndTurn(); BoardManager.instance.EndTurn(); CurrentPhase = PhaseState.EndOfTurn; }
/// <summary> /// Set current state to performing a QTE /// </summary> void EnterStateAttackQTE() { currentPhaseStateMethod = new CurrentPhaseState(StateAttackQTE); CurrentlySelectedUnit.AbilityActivator.FinishAbility(); CurrentPhase = PhaseState.AttackQTE; }
/// <summary> /// Set the current state to select an attack /// </summary> void EnterStateTargetAttack() { currentPhaseStateMethod = new CurrentPhaseState(StateTargetAttack); CombatUIManager.instance.StartTargetAttackPhase(); CurrentPhase = PhaseState.TargetAttack; }
/// <summary> /// Enter state while waiting for enemy team to go /// </summary> void EnterStateEnemyTurn() { currentPhaseStateMethod = new CurrentPhaseState(StateEnemyTurn); CombatUIManager.instance.StartEnemyTurnPhase(); CurrentlySelectedUnit = null; AIManager.StartEnemyTurn(); CurrentPhase = PhaseState.EnemyTurn; }
/// <summary> /// Set the current state to select an attack /// </summary> void EnterStateSelectAttack() { currentPhaseStateMethod = new CurrentPhaseState(StateSelectAttack); CombatUIManager.instance.StartSelectAttackPhase(); CurrentlySelectedUnit.AbilityActivator.FinishAbility(); BoardManager.instance.FinishMovement(); CurrentPhase = PhaseState.SelectAttack; }
/// <summary> /// Set the current state to movement selection /// </summary> void EnterStateMovementSelection() { currentPhaseStateMethod = new CurrentPhaseState(StateMovementSelection); CombatUIManager.instance.StartMovementPhase(); CurrentPhase = PhaseState.SelectMovement; currentMoveDistance = CurrentlySelectedUnit.remainingMoveDistance; if (CurrentlySelectedUnit.CanMove()) { BoardManager.instance.HighlightMovement(currentMoveDistance, CurrentlySelectedUnit.CurrentlyOccupiedHexagon); } CurrentlySelectedUnit.MovementIsDirty = false; }
/// <summary> /// Set the current state to Waiting /// </summary> void EnterStateWaiting() { currentPhaseStateMethod = new CurrentPhaseState(StateWait); CurrentPhase = PhaseState.Waiting; }