Ejemplo n.º 1
0
        private void addPromotionCellToList(ShopEntry shopEntry, RemotePromotion promotion, RectTransform parentTm)
        {
            PromotionCard.Content content2 = new PromotionCard.Content();
            content2.Promotion     = promotion;
            content2.RemoteTexture = promotion.ParsedCustomParams.ShopBannerImage;
            PromotionCard.Content content = content2;
            PromotionCard         item    = PlayerView.Binder.PromotionCardAugmentationPool.getObject();

            item.transform.SetParent(parentTm, false);
            item.initialize(content, new Action <Card>(this.onCardClicked));
            this.m_promotionCards.Add(item);
            item.gameObject.SetActive(true);
        }
Ejemplo n.º 2
0
 private void cleanupCells()
 {
     for (int i = this.m_promotionCards.Count - 1; i >= 0; i--)
     {
         PromotionCard item = this.m_promotionCards[i];
         this.m_promotionCards.Remove(item);
         PlayerView.Binder.PromotionCardAugmentationPool.returnObject(item);
     }
     for (int j = this.m_augCards.Count - 1; j >= 0; j--)
     {
         Card card2 = this.m_augCards[j];
         this.m_augCards.Remove(card2);
         PlayerView.Binder.CardButtonPool.returnObject(card2);
     }
     for (int k = this.m_vendorCards.Count - 1; k >= 0; k--)
     {
         Card card3 = this.m_vendorCards[k];
         this.m_vendorCards.Remove(card3);
         PlayerView.Binder.CardButtonPool.returnObject(card3);
     }
 }