Updated on 1st Dec 2021

Items and Inventory

Included with VRGK is a Inventory and Items System. By default you have 5 Inventory Slots, 2 for Tools and Weapons behind your Shoulders and 3 for Accessories (Hats, Glasses, Masks). Equipping an Item is as simple as moving your hand to the slot, which could mean to your face or behind your shoulders.

Inventory Items

Making an Object into a storable Item is as easy as adding a BPC_VRInventoryItem Component to it. It's important that the ROOT Component of the Actor is a Primitive Component (Static Mesh)! For every Item you can specify a custom relative location and rotation. This sets the Transform of the Objects in the Inventory Slot and decides which way you grab the object and drop it out of the inventory again. Additionally you can add an Item Tag and let it decide if it can be stored in any Slot or only in Slots with the compatible Item Tag.

Inventory Slots

Every Inventory Slot can spawn a Sound on Storing an Item or Dropping an Item. Additionally you can set it only allow Objects with a certain Item Tag. The Accessory Slots for example are only allowed to store Hats, Glasses and Masks.