Esempio n. 1
0
 public void CheckIfAchievementIsUnlocked()
 {
     if (PlayerPrefs.GetInt(achievementType.ToString()) == 0)
     {
         text.color = Color.red;
     }
     else
     {
         text.color = Color.green;
         isUnlocked = true;
     }
 }
Esempio n. 2
0
        public AchievementStatus GetAchievementStatus(AchievementTypes _type, int _id)
        {
            int _statusInt = PlayerPrefs.GetInt("Player" + _id.ToString() + _type.ToString());

            if (_statusInt == 1)
            {
                return(AchievementStatus.FINISHED);
            }
            else
            {
                return(AchievementStatus.UNFINISHED);
            }
        }
Esempio n. 3
0
 public void SetAchievementStatus(AchievementTypes _type, int _id, int _status)
 {
     PlayerPrefs.SetInt("Player" + _id.ToString() + _type.ToString(), _status);
 }