// Use this for initialization public override void Start() { base.Start(); World = PrefabRepository.Instance.World; BlockSelector = PrefabRepository.Instance.BlockSelector; BlockSelector = Instantiate(BlockSelector, new Vector3(0, 0), Quaternion.identity); SelectedItemGameObject = GameObject.Find("SelectedItemGameObject"); Inventory = new Inventory(this); ItemBar = new ItemBar(this); ItemBar loadedItemBar = (ItemBar)ItemBar.Load(); Inventory loadedInventory = (Inventory)Inventory.Load(); if (loadedInventory != null) { Inventory.Slots = loadedInventory.Slots; } if (loadedItemBar != null) { ItemBar.Slots = loadedItemBar.Slots; } Inventory.Show = false; Inventory.DrawUi(); Inventory.ToggleSlots(false); ItemBar.Show = true; ItemBar.DrawUi(); ItemBar.UpdateSelectedItemGameObject(); }