예제 #1
0
    public void OpenEquipStrengthen()
    {
        isEquipType = true;

        GameObject obj = Instantiate(Resources.Load("UI/Prefabs/HeroStrengthen/EquipmentPanel")) as GameObject;

        obj.transform.SetParent(transform, false);
        m_EquipmentPanel = obj.transform.GetComponent <EquipmentPanel> ();

        // 切换标题
        selfTransform.Find("TopPanel/TopTittle/Title").gameObject.SetActive(false);
        selfTransform.Find("TopPanel/TopTittle/Title_2").gameObject.SetActive(true);

        ClickSwitchBtn(m_EquipStrengthenUI, 6);

        if (m_EquipmentPanel != null)
        {
            m_EquipmentPanel.UpdateInfo(m_CurCard);
        }

        //
        m_BtnGroups.SetActive(false);
        m_EquipGroups.SetActive(true);

        m_Facelift.gameObject.SetActive(false);
        //


        //

        //
    }
예제 #2
0
    public void OnRefreshHero()
    {
        //SortHero ();

        if (m_CurCard == null)
        {
            m_CurCard = m_HeroList [0];
        }

        int count = ObjectSelf.GetInstance().HeroContainerBag.GetHeroList().Count;

        for (int i = 0; i < count; ++i)
        {
            ObjectCard card = m_HeroList [i];
            if (card.GetGuid() == m_CurCard.GetGuid())
            {
                m_CurCard = card;
                break;
            }
        }

        // 刷新英雄列表
        //m_HeroLayout.UpdateCell ();

        // 更新英雄信息
        UpdateHeroInfo();

        // 更新资质信息
        UpdateQualification();

        // 更新下面属性面板
        UpdateHeroAttr();

        // 更新右边属性面板
        if (m_CurAttrPanel != null)
        {
            m_CurAttrPanel.ShowHeroInfo(m_CurCard);
        }

        if (isEquipType)
        {
            m_EquipmentPanel.UpdateInfo(m_CurCard);
        }

        Show3DModel(m_CurCard);
    }