Animation Slot Event Trigger
AnimationSlotEventTrigger is a subclass of the AnimationEventTrigger. AnimationSlotEventTriggers are often used with ItemActions to wait for an Animation Event or a constant duration.
When the WaitForAnimationEvent field is enabled the event will only trigger once the Animator sends an aniomation event with the correct name. For consistency the animation name used will always be the relative to the field name.
“OnAnimatorItem”<FieldName>
The “UseComplete” field will wait for the “OnAnimatorItemUseComplete” animation event.
The AnimationSlotEventTrigger allows the option to use the SlotID of the Item within the animation event name. If the WaitForSlotEvent option is ticked the animation event name should be
“OnAnimatorItem”<FieldName>”Slot”<SlotID>
The AnimationSlotEventTrigger is registered and unregistered with:
m_UseEvent.RegisterUnregisterEvent(register, eventTarget,"OnAnimatorItemUse",m_CharacterItem.SlotID, HandleItemUseAnimationSlotEvent);
The event can be scheduled with:
m_UseEvent.WaitForEvent(true);
This will start the scheduled call or wait for the animation event.