Esempio n. 1
0
    public void SetTalkText()
    {
        this.currentGameGuideInfo = NrTSingleton <GameGuideManager> .Instance.GetGameGuideInfo();

        if (this.currentGameGuideInfo != null)
        {
            if (this.currentGameGuideInfo.m_eType == GameGuideType.DEFAULT)
            {
                this.talkText.SetFlashLabel(NrTSingleton <GameGuideManager> .Instance.GetDefaultGuideText());
            }
            else
            {
                this.talkText.SetFlashLabel(NrTSingleton <GameGuideManager> .Instance.GetGameGuideText());
                this.excute.Text = NrTSingleton <NrTextMgr> .Instance.GetTextFromInterface(this.currentGameGuideInfo.m_strButtonKey);

                if (this.currentGameGuideInfo.m_eType == GameGuideType.EQUIP_ITEM)
                {
                    GameGuideEquip gameGuideEquip = this.currentGameGuideInfo as GameGuideEquip;
                    if (gameGuideEquip != null)
                    {
                        base.SetShowLayer(2, true);
                        if (gameGuideEquip.GetSrcItem() != null && gameGuideEquip.GetDestItem() == null)
                        {
                            this.item1.ClearData();
                            this.item1.SetTexture("Win_T_ItemEmpty");
                            this.item2.SetItemTexture(gameGuideEquip.GetSrcItem());
                        }
                        else if (gameGuideEquip.GetSrcItem() != null && gameGuideEquip.GetDestItem() != null)
                        {
                            this.item1.SetItemTexture(gameGuideEquip.GetDestItem());
                            this.backItem1.SetTexture(gameGuideEquip.GetDestItem().GetRankImage());
                            this.item2.SetItemTexture(gameGuideEquip.GetSrcItem());
                        }
                    }
                }
                else if (this.currentGameGuideInfo.m_eType == GameGuideType.EQUIP_SELL && NrTSingleton <NkCharManager> .Instance.GetMyCharInfo().GetEquipSellMoney() == 0L && NrTSingleton <NkCharManager> .Instance.GetMyCharInfo().EquipMoneyAttackPlunder)
                {
                    NrTSingleton <NkCharManager> .Instance.GetMyCharInfo().EquipMoneyAttackPlunder = false;

                    this.excute.SetText(NrTSingleton <NrTextMgr> .Instance.GetTextFromInterface("10"));
                }
            }
        }
    }