private void HandleTutorialItem(TutorialItem tutorialItem) { _tutorialTextField.Type(PlayerPrefStringResolver.Instance.Resolve(tutorialItem.Text)); switch (tutorialItem.Action) { case TutorialItemActionType.ShowTemperatureMeter: _temperatureUiController.Hide(false); break; case TutorialItemActionType.CameraShake: CameraManager.Instance.Shake(0.2f); break; case TutorialItemActionType.SpawnFireball: _fireballSpawner.Spawn(); _fireballSpawner.Invoke("Spawn", 0.6f); break; case TutorialItemActionType.Mayhem: NpcManager.Instance.UnleashTheChaos(); break; case TutorialItemActionType.None: default: break; } }
internal void Display(int playerHealth) { var previousColour = Console.ForegroundColor; var barHealthNumber = 100 * playerHealth / maxHealthpoints; Console.ForegroundColor = ConsoleColor.DarkRed; for (int i = 0; i < barHealthNumber; i++) { if (i == critical) { Console.ForegroundColor = ConsoleColor.Yellow; } else if (i == danger) { Console.ForegroundColor = ConsoleColor.Green; } TypeWriter.Type("|", TypeWriter.Speed.List); } Console.ForegroundColor = previousColour; }