blaurain
Member
Hey there, I've spent the whole week working on adding a skill bar to my integration of UCC and UIS. The idea is that you can use these magic spells/skills at any time with other items equipped in the main slots. I read every other post I could find related to this and saw the general advice is to create new slots to house something like this and also a new set of equip/unequip skills to deal with those. My plan is to assign these three character spells to slots 2, 3 and 4. I converted my spells over to item objects and created a cast item action to cast from the skill bar and all that, I wont go into everything I tried, let me know if you have any questions here's what I have it's close to working but not quite there... I need help figuring out the rest please
You can see my bar at the bottom, I inherited from hotbar and cloned all that to create my own skill bar (hot bar is still active on the top, I didn't mess with any of that). I've been able to "equip" my spells (you can see them in the"equipped" item collection of the database and in the character's inventory, but only the rifle says "(slot x)" next to it)."Spell" category is equippable but I circled where it says"IsEquipped" is still false. How do I properly set that isequipped flag to true, what am I missing?
I know it's overkill but here's all I ended up doing to equip one of the spells in my skillbar setup logic:
You can see my bar at the bottom, I inherited from hotbar and cloned all that to create my own skill bar (hot bar is still active on the top, I didn't mess with any of that). I've been able to "equip" my spells (you can see them in the"equipped" item collection of the database and in the character's inventory, but only the rifle says "(slot x)" next to it)."Spell" category is equippable but I circled where it says"IsEquipped" is still false. How do I properly set that isequipped flag to true, what am I missing?
I know it's overkill but here's all I ended up doing to equip one of the spells in my skillbar setup logic:
Code:
var item2 = InventorySystemManager.CreateItem(Slot2);
item2.AddItemCollection(m_Inventory.MainItemCollection);
m_Inventory.GetItemCollection(ItemCollectionPurpose.Equipped).AddItem(item2);
var itemInfo2 = (ItemInfo)(1, item2);
m_Inventory.gameObject.GetComponent<Equipper>().Equip(item2, 3);
EventHandler.ExecuteEvent<ItemInfo, bool>(m_Inventory.gameObject, "OnItemActionEquipUnequip", itemInfo2, true);
m_Inventory.AddItem(itemInfo2);