I have been working on creating an equipment view and I think I have everything setup the same way as the demo with just a different UI and Item View Slots Container for the Equipment but as I run I get this error and my one equip item doesn't show up.
IndexOutOfRangeException: Index was outside the bounds of the array.
Opsive.UltimateInventorySystem.UI.Views.ViewDrawerBase.RemoveBox (System.Int32 index) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Views/ViewDrawer.cs:146)
Opsive.UltimateInventorySystem.UI.Views.ViewDrawer`1[T].DrawView (System.Int32 boxIndex, System.Int32 elementIndex, T element, System.Boolean removePreviousBox) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Views/ViewDrawer.cs:237)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainer.AssignItemToSlot (Opsive.UltimateInventorySystem.Core.DataStructures.ItemInfo itemInfo, System.Int32 slot) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainer.cs:60)
Opsive.UltimateInventorySystem.UI.Panels.Hotbar.ItemSlotCollectionView.Draw () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/Hotbar/ItemSlotCollectionView.cs:218)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainerBase.HandleInventoryUpdate () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainerBase.cs:341)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainerBase.SetInventory (Opsive.UltimateInventorySystem.Core.InventoryCollections.Inventory inventory, System.Boolean handleChange) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainerBase.cs:288)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainerBase.SetInventory (Opsive.UltimateInventorySystem.Core.InventoryCollections.Inventory inventory) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainerBase.cs:266)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.ItemViewSlotsContainerPanelBinding.OnInventoryBound () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/ItemViewSlotsContainerPanelBinding.cs:78)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.InventoryPanelBinding.BindInventory (Opsive.UltimateInventorySystem.Core.InventoryCollections.Inventory inventory) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/InventoryPanelBinding.cs:71)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.InventoryPanelBinding.BindInventory () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/InventoryPanelBinding.cs:51)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.InventoryPanelBinding.Initialize (Opsive.UltimateInventorySystem.UI.Panels.DisplayPanel display) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/InventoryPanelBinding.cs:36)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.ItemViewSlotsContainerPanelBinding.Initialize (Opsive.UltimateInventorySystem.UI.Panels.DisplayPanel display) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/ItemViewSlotsContainerPanelBinding.cs:37)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanel.Setup (Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager manager) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanel.cs:129)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.SetupDisplayPanels (System.Boolean force) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:123)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.SetPanelOwner (UnityEngine.GameObject panelOwner) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:154)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.Initialize (System.Boolean force) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:112)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.Awake () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:72)
Hierarchy of Window in the canvas is
Panel w/ DisplayPanel, DisplayPanelSelector, ItemViewSlotsContainerPanelBinding,
- PanelContent
-- Equipment Item View Slot Container w/ ItemSlotCollectionView, ItemViewSlotDragHandler, ItemViewDropHandler, ItemViewDrawer
--- Item View Slots Content
---- Equipment (Rect Transform Only)
----- EquipSlots (Rect Transform Only)
------ Left (a Grid Layout Group)
------- Equip Slot (Head) w/ ItemViewSlot, ItemViewSlotCategoryRestriction
-------- Equipment Slot Item View w/ ItemView, IconItemView, DragOffView, DragHoverIconPreviewItemView and the Image for background of slot
--------- Slot Icon w/ Image
--------- ColorFillter w/ Image
-------- (Repeating more times of EquipSlot down)
------- And then repeat of right side equipment and middle equipment
Note: My player has in Inventory component an Equipment ItemSlotCollection that is Purpose Equipped assigned to the same ItemSlotSet I am using in the Equipment Item View Slot Container. Right now it has one item in the same ItemCategory as the Equip Slot (Head)
So any idea where I should look, I have been staring at this for a while.
Thanks,
IndexOutOfRangeException: Index was outside the bounds of the array.
Opsive.UltimateInventorySystem.UI.Views.ViewDrawerBase.RemoveBox (System.Int32 index) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Views/ViewDrawer.cs:146)
Opsive.UltimateInventorySystem.UI.Views.ViewDrawer`1[T].DrawView (System.Int32 boxIndex, System.Int32 elementIndex, T element, System.Boolean removePreviousBox) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Views/ViewDrawer.cs:237)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainer.AssignItemToSlot (Opsive.UltimateInventorySystem.Core.DataStructures.ItemInfo itemInfo, System.Int32 slot) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainer.cs:60)
Opsive.UltimateInventorySystem.UI.Panels.Hotbar.ItemSlotCollectionView.Draw () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/Hotbar/ItemSlotCollectionView.cs:218)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainerBase.HandleInventoryUpdate () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainerBase.cs:341)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainerBase.SetInventory (Opsive.UltimateInventorySystem.Core.InventoryCollections.Inventory inventory, System.Boolean handleChange) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainerBase.cs:288)
Opsive.UltimateInventorySystem.UI.Item.ItemViewSlotsContainerBase.SetInventory (Opsive.UltimateInventorySystem.Core.InventoryCollections.Inventory inventory) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Item/ItemViewSlotsContainerBase.cs:266)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.ItemViewSlotsContainerPanelBinding.OnInventoryBound () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/ItemViewSlotsContainerPanelBinding.cs:78)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.InventoryPanelBinding.BindInventory (Opsive.UltimateInventorySystem.Core.InventoryCollections.Inventory inventory) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/InventoryPanelBinding.cs:71)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.InventoryPanelBinding.BindInventory () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/InventoryPanelBinding.cs:51)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.InventoryPanelBinding.Initialize (Opsive.UltimateInventorySystem.UI.Panels.DisplayPanel display) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/InventoryPanelBinding.cs:36)
Opsive.UltimateInventorySystem.UI.Panels.ItemViewSlotContainers.ItemViewSlotsContainerPanelBinding.Initialize (Opsive.UltimateInventorySystem.UI.Panels.DisplayPanel display) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/ItemViewSlotContainers/ItemViewSlotsContainerPanelBinding.cs:37)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanel.Setup (Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager manager) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanel.cs:129)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.SetupDisplayPanels (System.Boolean force) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:123)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.SetPanelOwner (UnityEngine.GameObject panelOwner) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:154)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.Initialize (System.Boolean force) (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:112)
Opsive.UltimateInventorySystem.UI.Panels.DisplayPanelManager.Awake () (at Assets/Opsive/UltimateInventorySystem/Scripts/UI/Panels/DisplayPanelManager.cs:72)
Hierarchy of Window in the canvas is
Panel w/ DisplayPanel, DisplayPanelSelector, ItemViewSlotsContainerPanelBinding,
- PanelContent
-- Equipment Item View Slot Container w/ ItemSlotCollectionView, ItemViewSlotDragHandler, ItemViewDropHandler, ItemViewDrawer
--- Item View Slots Content
---- Equipment (Rect Transform Only)
----- EquipSlots (Rect Transform Only)
------ Left (a Grid Layout Group)
------- Equip Slot (Head) w/ ItemViewSlot, ItemViewSlotCategoryRestriction
-------- Equipment Slot Item View w/ ItemView, IconItemView, DragOffView, DragHoverIconPreviewItemView and the Image for background of slot
--------- Slot Icon w/ Image
--------- ColorFillter w/ Image
-------- (Repeating more times of EquipSlot down)
------- And then repeat of right side equipment and middle equipment
Note: My player has in Inventory component an Equipment ItemSlotCollection that is Purpose Equipped assigned to the same ItemSlotSet I am using in the Equipment Item View Slot Container. Right now it has one item in the same ItemCategory as the Equip Slot (Head)
So any idea where I should look, I have been staring at this for a while.
Thanks,