Ejemplo n.º 1
0
    /* Shows the QuestPopup window. */
    private void ShowQuestPopup(Quest quest, NPC startingNPC)
    {
        GameObject questPopupObj = Instantiate(Resources.Load <GameObject>("Prefabs/QuestSystem/Quest Pop-up/Quest Pop-up"), gameObject.transform);

        questPopup = questPopupObj.GetComponent <QuestPopup>();
        questPopup.Initialize(quest, startingNPC);
        questIsUp = true;
    }
Ejemplo n.º 2
0
 public override void Set(params object[] args)
 {
     questNumber = (int)args[0];
     questData = GameData.instance.GetQuestData(questNumber);
     questPopup = args[1] as QuestPopup;
     string buildingName = GameData.instance.GetBuildingData(questData.builds).name;
     Text txt = GetComponentInChildren<Text>();
     if (buildingName.Contains(" "))
         txt.text = buildingName.Split(' ')[0];
     else
         txt.text = buildingName;
 }