Example #1
0
 private void cleanupHeroCells()
 {
     for (int i = this.m_heroCells.Count - 1; i >= 0; i--)
     {
         HeroCell item = this.m_heroCells[i];
         this.m_heroCells.Remove(item);
         PlayerView.Binder.HeroCellPool.returnObject(item);
     }
 }
Example #2
0
        private HeroCell addHeroCellToGrid(CharacterInstance characterInstance, Character character)
        {
            HeroCell item = PlayerView.Binder.HeroCellPool.getObject();

            item.transform.SetParent(this.HeroCellGrid.transform, false);
            item.initialize(characterInstance, character);
            this.m_heroCells.Add(item);
            item.gameObject.SetActive(true);
            return(item);
        }