public void JustZoomToMission()
        {
            UiAnimMgr.instance.PlayAnim("MinimapPulseAnim", base.transform, Vector3.zero, 3f, 0f);
            Main.instance.m_UISound.Play_SelectMission();
            if (StaticDB.garrMissionDB.GetRecord(this.m_garrMissionID) == null)
            {
                return;
            }
            AdventureMapPanel         instance  = AdventureMapPanel.instance;
            StackableMapIcon          component = base.GetComponent <StackableMapIcon>();
            StackableMapIconContainer stackableMapIconContainer = null;

            if (component != null)
            {
                stackableMapIconContainer = component.GetContainer();
                AdventureMapPanel.instance.SetSelectedIconContainer(stackableMapIconContainer);
            }
            Vector2 tapPos;

            if (stackableMapIconContainer != null)
            {
                tapPos..ctor(stackableMapIconContainer.transform.position.x, stackableMapIconContainer.transform.position.y);
            }
            else
            {
                tapPos..ctor(base.transform.position.x, base.transform.position.y);
            }
            instance.CenterAndZoom(tapPos, null, true);
        }
Example #2
0
        public void OnClick()
        {
            Main.instance.m_UISound.Play_SelectWorldQuest();
            UiAnimMgr.instance.PlayAnim("MinimapPulseAnim", base.transform, Vector3.zero, 2f, 0f);
            AllPopups.instance.ShowWorldQuestTooltip(this.m_questID);
            StackableMapIcon component = base.GetComponent <StackableMapIcon>();

            if (component != null)
            {
                StackableMapIconContainer container = component.GetContainer();
                AdventureMapPanel.instance.SetSelectedIconContainer(container);
            }
        }
        public void JustZoomToMission()
        {
            Vector2 vector2;

            UiAnimMgr.instance.PlayAnim("MinimapPulseAnim", base.transform, Vector3.zero, 3f, 0f);
            Main.instance.m_UISound.Play_SelectMission();
            if (StaticDB.garrMissionDB.GetRecord(this.m_garrMissionID) == null)
            {
                return;
            }
            AdventureMapPanel         adventureMapPanel = AdventureMapPanel.instance;
            StackableMapIcon          component         = base.GetComponent <StackableMapIcon>();
            StackableMapIconContainer container         = null;

            if (component != null)
            {
                container = component.GetContainer();
                AdventureMapPanel.instance.SetSelectedIconContainer(container);
            }
            vector2 = (container == null ? new Vector2(base.transform.position.x, base.transform.position.y) : new Vector2(container.transform.position.x, container.transform.position.y));
            adventureMapPanel.CenterAndZoom(vector2, null, true);
        }