The Character Controller Inventory does not support character skinned mesh items. Clothes and armor must be equipped through the Ultimate Inventory System. The easiest way to do so is by using the
Equipper script.
Since armor and weapons will be equipped through different systems the clothes cannot be equipped with an “Equippable” ItemCollection, these are meant to be used purely for the Character Controller weapons. Therefore another ItemCollection must be used for clothes and armor.
- Create a new ItemSlotCollection for your armor and name it accordingly (i.e “Armor Equipped”), set its purpose to “None” such that it won’t be confused with the “Equippable” collections.
- Create an ItemSlotSet for your armor slots and assign it to your new ItemSlotCollection.
- Add an Equipper script to your character, assign the ItemSlotSet and define which slots are skinned mesh.
- Create an additional Equipment UI (aka ItemSlotCollectionView) separate from the weapons equipment UI. Make sure that each are set up correctly and point to the correct ItemSlotCollections.
- Use the MoveToItemCollection Item Action for equipping the armor in the UI and make sure the correct ItemCollection name is specified, The CharacterEquipItemAction should only be used for equipping “Equippable” Character Controller weapons.
- Create items with skinned mesh prefabs following the Equipper guidelines for skinned mesh equipments.
Since your armor and weapon items will be separated in two or more item collections you may wish to create an Item Collection Group to keep track of all your equipment in code.
The Equipper script is fairly simple, you may extend it or replace it with your own custom script to make it more advanced.