示例#1
0
 public void GiveQuest()
 {
     if (currentIndex < quests.Count)
     {
         QuestList questList = GameObject.FindGameObjectWithTag("Player").GetComponent <QuestList>();
         questList.AddQuest(quests[currentIndex]);
         Debug.Log("Dałem questa " + quests[currentIndex]);
         currentIndex++;
     }
 }
示例#2
0
        public void CompleteSelectedObjective(string objective)
        {
            QuestList questList = GameObject.FindWithTag("Player").GetComponent <QuestList>();

            foreach (QuestsToComplete questToComplete in questsToComplete)
            {
                if (questToComplete.quest.HasObjective(objective))
                {
                    questList.CompleteObjective(questToComplete.quest, objective);
                    return;
                }
            }
        }
        public void CompleteObjective()
        {
            QuestList questList = GameObject.FindGameObjectWithTag("Player").GetComponent <QuestList>();

            foreach (QuestStatus status in questList.GetStatuses())
            {
                if (status.GetQuestName() == questName && HasObjective(status) && !status.GetCompletedObjectives().Contains(objectiveName))
                {
                    status.CompleteObjective(objectiveName);
                    questList.RefreshQuestList();
                    canDestroy = true;
                }
            }
        }
示例#4
0
        public void GiveQuest()
        {
            QuestList questList = GameObject.FindGameObjectWithTag("Player").GetComponent <QuestList>();

            questList.AddQuest(quest);
        }
示例#5
0
        public void CompleteObjective()
        {
            QuestList questList = GameObject.FindGameObjectWithTag("Player").GetComponent <QuestList>();

            questList.CompleteObjective(quest, objective);
        }
示例#6
0
        public void UpdateQuestCompletion()
        {
            QuestList questList = GameObject.FindGameObjectWithTag("Player").GetComponent <QuestList>();

            questList.ClearQuest(_quest, _objectiveReference);
        }
示例#7
0
        public void GiveQuest()
        {
            QuestList player = GameObject.FindWithTag("Player").GetComponent <QuestList>();

            player.AddQuest(quest);
        }