Esempio n. 1
0
    protected override void Awake()
    {
        base.Awake();

        TimeLeft = LevelTime;

        initialStoneCount = Gems.Count;

        timeMinutes = 0;
        timeSeconds = 0;
        seconds     = null;

        LevelStats.InitStats();

        KillsUI.text = "0";

        StonesCollectedCount.text = "0 of " + initialStoneCount;

        RemainingUI.text = Enemies.Count.ToString();

        CurrentLevelState = LevelState.Active;

        TimeSlider.maxValue = LevelTime;
        TimeSlider.value    = 0;

        routineDone = false;

        // Subscribe
        Player.GetComponent <CharacterDamage>().PlayerDead += OnDeath;
    }