Skip to main content

Condition_HasSlotForHeldObject

Script condition function to check if a target object has an available slot for the held object.

This condition verifies whether the target game object (NonBaseObject) has an empty slot that can accommodate the object currently held in the character's (BaseObject) right hand. It checks slot availability based on object category and validates that the slot can be occupied.

Parameters

ParameterDescription
BaseObjectCharacter entity holding an object in right hand
CompareTypeEqual / NotEqual

Notes

  • The target game object is resolved internally via ScriptContext (NonBaseObject).
  • Returns false if the character does not have a valid PostureComponent.
  • Returns false if the target game object is invalid.
  • Returns false if the target object does not have a SlotComponent.
  • Returns false if the character is not holding an object in right hand.
  • Returns false if the held object's data table row is not found.
  • Searches for empty slots matching the held object's category.
  • Validates slot occupancy using SlotComponent.CanOccupySlot().

Examples

DescriptionBaseObjectCommandCompareType
Check if target has slot for held objectSelfHasSlotForHeldObjectEqual
Check if target has no slot availableSelfHasSlotForHeldObjectNotEqual