Exemplo n.º 1
0
 //Checks if we need to unblock the next level(only if there ara more levels available && if we are playing the last level unblocked)
 void CheckUnblockLevel()
 {
     if (currentLevel <= PlayerPrefsPersister.GetLevelReached() && currentLevel < levels.Count - 1)
     {
         PlayerPrefsPersister.SetLevelReached(currentLevel + 1);
     }
 }
Exemplo n.º 2
0
    private void Awake()
    {
        levelTimmings = RatingsManager.levelTimmings;
        if (levelTimmings == null || levelTimmings.Count == 0)
        {
            RatingsManager.FillLevels();
        }
        levelTimmings.OrderBy(l => l.LevelId);
        levelReached = PlayerPrefsPersister.GetLevelReached();

        //if(!Sound.instance.GetComponent<AudioSource>().enabled && PlayerPrefsPersister.GetAudioStatus())
        //{
        //    Sound.instance.GetComponent<AudioSource>().enabled = true;
        //}
    }