public void OnTextCompleted(int wordLength) { if (encouragePhrase.Count > 0) { wordDisplay.NewText(ladder.transform, encouragePhrase[0]); encouragePhrase.RemoveAt(0); } else { wordDisplay.StopDisplay(); ladderState = LadderStates.ClimbingLadder; hero.GetComponent <moveCharacter>().Climb(); } }
void Update() { switch (combatState) { case CombatStates.InputSetup: wordDisplay.NewText(tempEnemy.transform, list.GetWord(curDifficulty)); combatState = CombatStates.TakingInput; break; case CombatStates.HeroAttack: combatState = CombatStates.HeroAttacking; hero.GetComponent <moveCharacter>().Attack(); break; case CombatStates.EnemyAttack: combatState = CombatStates.EnemyAttacking; tempEnemy.GetComponent <Enemy>().Attack(); break; default: break; } }