1. Home
  2. Docs
  3. Damage Resource and Stat System
  4. Starter Guides
  5. Add your Inventory

Add your Inventory

Requirements

  • The inventory system must provide all values (crit, resistance, …) individually
  • The inventory must be a component

Step 1

Reparent your inventory to C_Inventory_Base. Then overwrite all “Get” functions and return the corresponding values.

In the componente C_Inventory_Example I did that by example and used fixed values.

You do not have to override all functions if you do not want to use the inventory for all values, but then you have to delete the corresponding function from C_Damage_Extended, C_Gameplay_Extended or C_Resource_Extended or the base value will always be 0!

Step 2

Make sure you use the extended versions from C_Damage, C_Gameplay and C_Resource. 
These components now get their base values from the inventory if one is found in the same actor.

Additional

Make sure you call OnBaseValueChange when a base value in the inventory change, to initilize the value recalculation 

How can we help?