void Awake() { _Instance = this; inventoryLabel = transform.Find("InventoryLabel").GetComponent <UILabel>(); InventoryManager._Instance.OnInventoryChangeEvent += this.OnInventoryChange; }
void Awake() { instance = this; countLabel = transform.Find("count").GetComponent <UILabel>(); priceLabel = transform.Find("price_bg/price").GetComponent <UILabel>(); sellBtn = transform.Find("sell_btn").GetComponent <UIButton>(); clearBtn = transform.Find("clear_btn").GetComponent <UIButton>(); InventoryManager.instance.OnInventoryChanged += OnInventoryChanged; }