Open 3D Engine EMotionFX Gem API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
EMotionFX::EventDataFootIK Class Reference

Inherits EMotionFX::EventData.

Public Types

enum class  Foot : uint32 { Left = 0 , Right = 1 , Both = 2 }
 

Public Member Functions

 AZ_RTTI (EventDataFootIK, "{2BF8BB82-F7B1-4833-BB1D-A2537D759E48}", EventData)
 
AZ_INLINE Foot GetFoot () const
 
AZ_INLINE bool GetIKEnabled () const
 
AZ_INLINE bool GetLocked () const
 
bool Equal (const EventData &rhs, bool ignoreEmptyFields=false) const override
 Test if two EventData instances are equal.
 
- Public Member Functions inherited from EMotionFX::EventData
 AZ_RTTI (EventData, "{F6AFCD3B-D58E-4821-9E7C-D1F437304E5D}")
 
virtual bool operator== (const EventData &rhs) const
 
virtual bool Equal (const EventData &rhs, bool ignoreEmptyFields=false) const =0
 Test if two EventData instances are equal.
 
virtual AZStd::string ToString () const
 

Static Public Member Functions

static void Reflect (AZ::ReflectContext *context)
 
- Static Public Member Functions inherited from EMotionFX::EventData
static void Reflect (AZ::ReflectContext *context)
 

Member Function Documentation

◆ Equal()

bool EMotionFX::EventDataFootIK::Equal ( const EventData rhs,
bool  ignoreEmptyFields = false 
) const
overridevirtual

Test if two EventData instances are equal.

This method is used by EMotionFX to deduplicate instances of EventData subclasses, and by the AnimGraphMotionCondition's Motion Event matching logic.

When loading a .motion file and deserializing the MotionEvents on the event tracks, each EventData instance is run through EventManager::FindOrCreateEventData. The EventManager stores a list of all EventData instances in use, and attempts to find one where Equal(loadedEventData) returns true. If it finds one that is equal, the duplicate data is discarded. So this method is essential in saving memory of the duplicated EventData instances.

When an AnimGraphMotionCondition is used to test against a Motion Event, this method is called by AnimGraphMotionCondition::TestCondition. In this case, ignoreEmptyFields is true. This allows the condition to match against parts of the EventData and not others. For example, if one of the fields is a string, and that string value is empty in the condition, it can act as a wildcard match for that field.

This method is not used by the AnimGraphSyncTrack to determine if events are the same for syncing (that method is EventDataSyncable::HashForSyncing).

Implements EMotionFX::EventData.


The documentation for this class was generated from the following file: