Beispiel #1
0
        private void InitLogEntries()
        {
            ClearEntries();
            m_quests.Clear();
            m_quests.AddRange(m_questHandler.GetActiveStepsByCategory(EQuestType.QUEST_TYPE_MAIN));
            m_quests.AddRange(m_questHandler.GetActiveStepsByCategory(EQuestType.QUEST_TYPE_SIDE));
            m_quests.AddRange(m_questHandler.GetActiveStepsByCategory(EQuestType.QUEST_TYPE_ONGOING));
            m_quests.AddRange(m_questHandler.GetActiveStepsByCategory(EQuestType.QUEST_TYPE_GRANDMASTER));
            m_quests.AddRange(m_questHandler.GetActiveStepsByCategory(EQuestType.QUEST_TYPE_PROMOTION));
            Int32 num = 0;

            foreach (QuestStep p_questStep in m_quests)
            {
                GameObject          gameObject = NGUITools.AddChild(m_entryHook, m_prefabEntry);
                NewHUDQuestLogEntry component  = gameObject.GetComponent <NewHUDQuestLogEntry>();
                component.Init(p_questStep, num, this, false);
                ScrollingHelper.InitScrollListeners(this, gameObject);
                component.BusinessChanged += OnBusinessChanged;
                component.QuestHovered    += OnQuestHovered;
                m_entries.Insert(num, component);
                m_busyEntries.Add(component);
                num++;
            }
            RepositionEntries();
            if (m_entries.Count > 0)
            {
                m_currentlyVisibleEntry = m_entries[0];
            }
        }