Пример #1
0
    public void updateDailyQuest(int dailyQuestID)
    {
        PlayerDailyQuest[] list = dailyQuests.GetAll();
        int length = list.Length;

        for (int i = 0; i < length; i++)
        {
            if (list[i].id == dailyQuestID)
            {
                list[i].Amount++;
                break;
            }
        }

        listDailyQuest [dailyQuestID]++;

        dailyQuests.Save();
    }
Пример #2
0
    public void updateAchiement(int _id, object _value)
    {
        PlayerAchievement[] list = achievements.GetAll();
        int length = list.Length;

        for (int i = 0; i < length; i++)
        {
            if (list[i].id == _id)
            {
                list[i].value      = _value;
                listAchievement[i] = _value;
                break;
            }
        }

        achievements.Save();
    }
Пример #3
0
    public void addEnemy(string enemyID)
    {
        PlayerEnemy[] list   = enemies.GetAll();
        int           length = list.Length;

        for (int i = 0; i < length; i++)
        {
            if (list[i].id.Equals(enemyID))
            {
                if (!list[i].visible)
                {
                    list[i].visible = true;
                }
                break;
            }
        }

        listEnemy[enemyID] = true;

        enemies.Save();
    }