Pickup

The Pickup ability will play an animation which picks up an object. This animation could be picking up the object from the ground or on a table. This ability is a child of the Detect Object Ability Base so will inherit any properties from it.

Setup

  1. Select the + button in the ability list under the “Abilities” foldout of the Ultimate Character Locomotion component.
  2. Add the Pickup Item ability. This ability should be positioned near the top of the list so another ability will not prevent the character from picking up an item.

Inspected Fields

Allowed Pickups

Specifies the type of object that can be picked up:

  • Item: Items can be picked up.
  • Health: Health objects can be picked up.
  • Other: Any other object can be picked up.
Slot ID

The slot ID of the item that can be picked up. A value of -1 indicates any slot.

Pickup Item Definitions

Specifies a list of Item Definitions that should be picked up. If the list is empty any Item Definition will trigger the animation.

Pickup Event

Specifies if the ability should wait for the OnAnimatorPickup animation event or wait the specified amount of time before picking up the item.

Pickup Complete Event

Specifies if the ability should wait for the OnAnimatorPickupComplete animation event or wait the specified amount of time before stopping the ability.