private void Awake() { gameObject.SetActive(false); partyPanel = FindObjectOfType <UIPartyPanel>(); playerInfoPanel = FindObjectOfType <UIPlayerInfoPanel>(); characterController = FindObjectOfType <BattleSystem.CharacterController>(); }
private void Awake() { if (FindObjectsOfType <InventoryController>().Length > 1) { Destroy(this.gameObject); } DontDestroyOnLoad(this.gameObject); inventories = GetComponentsInChildren <Inventory>(true); itemDatabase = FindObjectOfType <ItemDatabase>(); partyPanel = FindObjectOfType <UIPartyPanel>(); }
private void Awake() { craftingSlots = FindObjectOfType <CraftingSlots>(); equipmentSlots = FindObjectOfType <EquipmentSlots>(); partyPanel = FindObjectOfType <UIPartyPanel>(); tooltip = FindObjectOfType <Tooltip>(); selectedItem = GameObject.Find("SelectedItem").GetComponent <UIItem>(); spriteImage = GetComponent <Image>(); consumableInventory = FindObjectOfType <ConsumableInventory>(); craftingInventory = FindObjectOfType <CraftingInventory>(); inventoryController = FindObjectOfType <InventoryController>(); UpdateItem(null); }