예제 #1
0
 public void InitData(HeroaddstageTemplate _CurTData, HeroaddstageTemplate _NextTData)
 {
     m_CurTData      = _CurTData;
     m_NextTData     = _NextTData;
     m_HeroStarLevel = _CurTData.getQuality();
     m_HeroCurStage  = _CurTData.getHalosPn();
     GreatAttributeItem();
     Invoke("onClose", 2f);
 }
예제 #2
0
    /// <summary>
    /// 显示星级,阶数
    /// </summary>
    private void InitShowStarAndStage()
    {
        m_CurStartHalosPnText.text  = GameUtils.getString("ui_yingxiongqianghua_jinjie2").Replace("{0}", m_HeroData.StarLevel.ToString()).Replace("{1}", m_HeroData.CurStage.ToString());
        m_NextStartHalosPnText.text = GameUtils.getString("ui_yingxiongqianghua_jinjie2").Replace("{0}", m_NextTData.getQuality().ToString()).Replace("{1}", m_NextTData.getHalosPn().ToString());
        //m_NextStartHalosPnInfoText.text = GameUtils.getString("ui_yingxiongqianghua_jinjie4") + GameUtils.getString("ui_yingxiongqianghua_jinjie2").Replace("{0}", m_NextTData.getQuality().ToString()).Replace("{1}", m_NextTData.getHalosPn().ToString());
        m_NextStartHalosPnInfoText.text = GameUtils.getString("ui_yingxiongqianghua_jinjie7");
        m_SpendText.text     = m_NextTData.getGold().ToString();
        m_LevelOpenText.text = "";

        int curStarMaxRank = GameUtils.GetCurStarMaxHalosPn(m_HeroDataT.getBorn(), m_HeroDataT.getQosition(), m_HeroData.StarLevel);//当前星级的最大阶数

        for (int i = 0; i < m_GrayGO.Count; i++)
        {
            m_GrayGO[i].SetActive(i < curStarMaxRank);
        }
        for (int i = 0; i < m_LightGO.Count; i++)
        {
            m_LightGO[i].SetActive(i < m_HeroData.CurStage);
        }
        for (int i = 0; i < m_StarGO.Count; i++)
        {
            m_StarGO[i].SetActive(false);
            m_StarGO[i].SetActive(i < m_HeroData.StarLevel);
        }
    }
예제 #3
0
    public override void ShowHeroInfo(ObjectCard objectCard)
    {
        m_HeroData  = objectCard.GetHeroData();
        m_HeroDataT = objectCard.GetHeroRow();

        m_CurTData  = GameUtils.GetCurAdvancedData(m_HeroDataT.getBorn(), m_HeroDataT.getQosition(), m_HeroData.StarLevel, m_HeroData.CurStage);
        m_NextTData = GameUtils.GetHeroNextAdvancedData(objectCard);

        YesAdvancedEffect.gameObject.SetActive(false);

        if (m_HeroData.StarLevel == m_NextTData.getQuality() && m_HeroData.CurStage == m_NextTData.getHalosPn())
        {
            m_MaxLevelWindow.SetActive(true);
            m_NoMaxLevelWindow.SetActive(false);
        }
        else
        {
            m_MaxLevelWindow.SetActive(false);
            m_NoMaxLevelWindow.SetActive(true);

            InitShowStarAndStage();
            GreatAttributeItem();
            GreatArticleItem();
        }

        RefreshLevelNoEnoughtTip();
    }