Пример #1
0
 private void UpdateItems()
 {
     foreach (object obj in ItemsContainer.Items)
     {
         ShopWindowItem shopWindowItem = obj as ShopWindowItem;
         shopWindowItem.HideIfOwned(GameManager.Instance.PC.items);
     }
 }
Пример #2
0
        public ShopWindow(Shop shop) : this()
        {
            using (Dispatcher.DisableProcessing())
            {
                IEnumerable <Item> items = shop.Items.getItems();

                foreach (Item item in items)
                {
                    ShopWindowItem shopWindowItem = new ShopWindowItem(this, item);
                    ItemsContainer.Items.Add(shopWindowItem);
                }
                Update();
            }
        }