Ejemplo n.º 1
0
        public void RefreshVoiceStateIfNess()
        {
            CUIFormScript statViewFormScript = this.m_statViewFormScript;

            if (statViewFormScript == null)
            {
                return;
            }
            if (!statViewFormScript.IsHided())
            {
                for (int i = 0; i < this.m_playerListCamp1.get_Count(); i++)
                {
                    if (i >= this._heroList0.Length)
                    {
                        break;
                    }
                    Player curPlayer = this.m_playerListCamp1.get_Item(i);
                    BattleStatView.HeroItem heroItem = this._heroList0[i];
                    heroItem.updateHeroVoiceState(curPlayer);
                }
                for (int i = 0; i < this.m_playerListCamp2.get_Count(); i++)
                {
                    if (i >= this._heroList1.Length)
                    {
                        break;
                    }
                    Player curPlayer = this.m_playerListCamp2.get_Item(i);
                    BattleStatView.HeroItem heroItem = this._heroList1[i];
                    heroItem.updateHeroVoiceState(curPlayer);
                }
            }
        }
Ejemplo n.º 2
0
        private void UpdateBattleState(CUIEvent evt = null)
        {
            if (null == this._root)
            {
                return;
            }
            CUIFormScript statViewFormScript = this.m_statViewFormScript;

            if (statViewFormScript == null)
            {
                return;
            }
            if (!statViewFormScript.IsHided())
            {
                for (int i = 0; i < this.m_playerListCamp1.get_Count(); i++)
                {
                    if (i >= this._heroList0.Length)
                    {
                        break;
                    }
                    Player curPlayer = this.m_playerListCamp1.get_Item(i);
                    BattleStatView.HeroItem heroItem = this._heroList0[i];
                    heroItem.updateReviceCD(curPlayer);
                    heroItem.updateTalentSkillCD(curPlayer, this.m_statViewFormScript);
                    if (this.m_battleHeroPropertyChange)
                    {
                        heroItem.updateHeroValue(curPlayer);
                    }
                }
                for (int i = 0; i < this.m_playerListCamp2.get_Count(); i++)
                {
                    if (i >= this._heroList1.Length)
                    {
                        break;
                    }
                    Player curPlayer = this.m_playerListCamp2.get_Item(i);
                    BattleStatView.HeroItem heroItem = this._heroList1[i];
                    heroItem.updateReviceCD(curPlayer);
                    heroItem.updateTalentSkillCD(curPlayer, this.m_statViewFormScript);
                    if (this.m_battleHeroPropertyChange)
                    {
                        heroItem.updateHeroValue(curPlayer);
                    }
                }
                if (this.m_battleHeroPropertyChange)
                {
                    this.m_battleHeroPropertyChange = false;
                }
            }
        }
Ejemplo n.º 3
0
 private void onSoulLvlChange(PoolObjHandle <ActorRoot> act, int curVal)
 {
     if (!this._root)
     {
         return;
     }
     BattleStatView.HeroItem[] array = this._heroList0;
     for (int i = 0; i < array.Length; i++)
     {
         BattleStatView.HeroItem heroItem = array[i];
         if (heroItem != null && heroItem.Visible && heroItem.kdaData != null && heroItem.kdaData.actorHero == act)
         {
             heroItem.level.text = curVal.ToString();
         }
         if (i + 1 == array.Length && array == this._heroList0)
         {
             array = this._heroList1;
             i     = -1;
         }
     }
 }