Exemplo n.º 1
0
 private void UpdateBattleState(CUIEvent evt = null)
 {
     if ((null != this._root) && !Singleton <CUIManager> .GetInstance().GetForm(s_battleStateViewUIForm).IsHided())
     {
         int      index     = 0;
         Player   curPlayer = null;
         HeroItem item      = null;
         for (index = 0; index < this.m_playerListCamp1.Count; index++)
         {
             if (index >= this._heroList0.Length)
             {
                 break;
             }
             curPlayer = this.m_playerListCamp1[index];
             item      = this._heroList0[index];
             item.updateReviceCD(curPlayer);
             item.updateTalentSkillCD(curPlayer);
             if (this.m_battleHeroPropertyChange)
             {
                 item.updateHeroValue(curPlayer);
             }
         }
         for (index = 0; index < this.m_playerListCamp2.Count; index++)
         {
             if (index >= this._heroList1.Length)
             {
                 break;
             }
             curPlayer = this.m_playerListCamp2[index];
             item      = this._heroList1[index];
             item.updateReviceCD(curPlayer);
             item.updateTalentSkillCD(curPlayer);
             if (this.m_battleHeroPropertyChange)
             {
                 item.updateHeroValue(curPlayer);
             }
         }
         if (this.m_battleHeroPropertyChange)
         {
             this.m_battleHeroPropertyChange = false;
         }
     }
 }