public void InitElementSkill(int skillid)
    {
        Tab_CabalFellowElementSkill tabSkill = TableManager.GetCabalFellowElementSkillByID(skillid, 0);

        if (tabSkill == null)
        {
            return;
        }

        Tab_SkillEx tabSkillEx = TableManager.GetSkillExByID(skillid, 0);

        if (tabSkillEx == null)
        {
            return;
        }

        Tab_SkillBase tabBase = TableManager.GetSkillBaseByID(tabSkillEx.BaseId, 0);

        if (tabBase == null)
        {
            return;
        }

        m_TallentSkillId = GlobeVar.INVALID_ID;
        m_ElementSkillId = skillid;

        m_NameLabel.text       = tabBase.Name;
        m_LevelLabel.text      = FellowTool.GetFellowElementLevelText(skillid);
        m_DescLabel.text       = tabSkillEx.SkillDesc;
        m_SkillIcon.spriteName = tabBase.Icon;
        //m_QualityPic.spriteName = FellowTool.GetFellowElementSkillQualityPic(skillid);
    }
    void InitElementSkill_Info(int skillid)
    {
        Tab_CabalFellowElementSkill tabSkill = TableManager.GetCabalFellowElementSkillByID(skillid, 0);

        if (tabSkill == null)
        {
            return;
        }

        Tab_SkillEx tabSkillEx = TableManager.GetSkillExByID(skillid, 0);

        if (tabSkillEx == null)
        {
            return;
        }

        Tab_SkillBase tabBase = TableManager.GetSkillBaseByID(tabSkillEx.BaseId, 0);

        if (tabBase == null)
        {
            return;
        }

        m_TallentSkillId = GlobeVar.INVALID_ID;
        m_ElementSkillId = skillid;

        Tab_CabalFellowElementSkill tabNextSkill = TableManager.GetCabalFellowElementSkillByID(tabSkill.NextSkillId, 0);

        if (tabNextSkill == null)
        {
            lblSkillLv.text = "MAX";
        }
        sprSkillIcon.spriteName = tabBase.Icon;
        sprSkillIcon.gameObject.SetActive(true);

        lblSkillLv.text = FellowTool.GetFellowElementLevelText(skillid);
        lblSkillLv.transform.parent.gameObject.SetActive(true);
        lblSkillName.text = tabBase.Name;
        lblSkillDesc.text = tabBase.SkillIntro;
        objLock.SetActive(false);
        enhanceSkill.SetActive(true);
        UIEventListener.Get(enhanceSkill).onClick = ShowEnhanceDialog;
        if (PartnerFrameLogic.Instance() != null)
        {
            PartnerFrameLogic.Instance().UpdateDevelopRemindPoint();
        }
    }
Beispiel #3
0
    public void InitElementSkill_Info(int skillid)
    {
        Tab_CabalFellowElementSkill tabSkill = TableManager.GetCabalFellowElementSkillByID(skillid, 0);

        if (tabSkill == null)
        {
            return;
        }

        Tab_SkillEx tabSkillEx = TableManager.GetSkillExByID(skillid, 0);

        if (tabSkillEx == null)
        {
            return;
        }

        Tab_SkillBase tabBase = TableManager.GetSkillBaseByID(tabSkillEx.BaseId, 0);

        if (tabBase == null)
        {
            return;
        }

        m_TallentSkillId = GlobeVar.INVALID_ID;
        m_ElementSkillId = skillid;

        m_NameLabel.text = tabBase.Name;
        m_NameLabel.gameObject.SetActive(true);

        Tab_CabalFellowElementSkill tabNextSkill = TableManager.GetCabalFellowElementSkillByID(tabSkill.NextSkillId, 0);

        if (tabNextSkill == null)
        {
            m_ExpLabel.text = "MAX";
        }
        else
        {
            m_ExpLabel.text = StrDictionary.GetClientDictionaryString("#{10321}", GameManager.gameManager.PlayerDataPool.BackPack.GetItemCountByDataId(tabNextSkill.NeedBookId), tabNextSkill.NeedBookCount);
        }
        m_ExpLabel.gameObject.SetActive(true);

        m_SkillIcon.spriteName = tabBase.Icon;
        m_SkillIcon.gameObject.SetActive(true);

        m_QualityPic.spriteName = FellowTool.GetFellowElementSkillQualityPic(skillid);

        m_LevelLabel.text = FellowTool.GetFellowElementLevelText(skillid);
        m_LevelLabel.gameObject.SetActive(true);

        m_FlagLabel.gameObject.SetActive(false);
        m_LockSprite.SetActive(false);

        if (m_LevelUpButton != null)
        {
            m_LevelUpButton.SetActive(tabSkill.NextSkillId != GlobeVar.INVALID_ID);
        }

        updateElementRemindPoint(skillid);
        if (PartnerFrameLogic.Instance() != null)
        {
            PartnerFrameLogic.Instance().UpdateDevelopRemindPoint();
        }
    }
    public void Init(int skillid, int index, int fellowlevel)
    {
        if (skillid == GlobeVar.INVALID_ID)
        {
            if (index < 0 || index >= Fellow.FELLOW_ELEMENTSKILL_LEVELNEED.Length)
            {
                return;
            }

            m_SkillIcon.gameObject.SetActive(false);
            //m_QualityPic.spriteName = "white-jinengkuang";
            m_UnLockButton.SetActive(false);
            int LvValue = Fellow.FELLOW_ELEMENTSKILL_LEVELNEED[index];
            m_Level.text = LvValue.ToString();
            if (fellowlevel >= LvValue)
            {
                m_LockButton.SetActive(true);
                m_NoHoldSprite.SetActive(false);
                m_bValidSlot = true;
                m_bLocked    = false;
            }
            else
            {
                m_LockButton.SetActive(false);
                m_NoHoldSprite.SetActive(true);
                m_bValidSlot = false;
                m_bLocked    = true;
            }
        }
        else
        {
            Tab_CabalFellowElementSkill tabSkill = TableManager.GetCabalFellowElementSkillByID(skillid, 0);
            if (tabSkill == null)
            {
                return;
            }

            Tab_SkillEx tabSkillEx = TableManager.GetSkillExByID(skillid, 0);
            if (tabSkillEx == null)
            {
                return;
            }

            Tab_SkillBase tabBase = TableManager.GetSkillBaseByID(tabSkillEx.BaseId, 0);
            if (tabBase == null)
            {
                return;
            }

            m_SkillIcon.spriteName = tabBase.Icon;
            m_SkillIcon.gameObject.SetActive(true);
            Tab_CabalFellowElementSkill tabNextSkill = TableManager.GetCabalFellowElementSkillByID(tabSkill.NextSkillId, 0);
            if (tabNextSkill == null)
            {
                m_Level.text = "MAX";
            }
            m_Level.text = FellowTool.GetFellowElementLevelText(skillid);

            m_LockButton.SetActive(true);
            m_UnLockButton.SetActive(false);

            m_NoHoldSprite.SetActive(false);

            m_bValidSlot = true;
            m_bLocked    = false;
        }
    }