IAnimationPoseBlenderDir

IAnimationPoseBlenderDirabstract

#include

Inherits IAnimationPoseModifier.

Public Member Functions

CRYINTERFACE_DECLARE_GUID (IAnimationPoseBlenderDir, "1725a49d-bd68-4ff4-852c-d0d4b7f86c28"_cry_guid)
virtual void SetState (bool state)=0
virtual void SetTarget (const Vec3 &target)=0
Location of the target we want to aim at, in world coordinates.
virtual void SetLayer (uint32 nLayer)=0
virtual void SetFadeoutAngle (f32 angleRadians)=0
virtual void SetFadeOutSpeed (f32 time)=0
virtual void SetFadeInSpeed (f32 time)=0
virtual void SetFadeOutMinDistance (f32 minDistance)=0
virtual void SetPolarCoordinatesOffset (const Vec2 &offset)=0
virtual void SetPolarCoordinatesSmoothTimeSeconds (f32 smoothTimeSeconds)=0
virtual void SetPolarCoordinatesMaxRadiansPerSecond (const Vec2 &maxRadiansPerSecond)=0
virtual f32 GetBlend () const =0
- Public Member Functions inherited from IAnimationPoseModifier
CRYINTERFACE_DECLARE_GUID (IAnimationPoseModifier, "22fe4775-5e42-447f-bab6-274ed39af449"_cry_guid)
virtual bool Prepare (const SAnimationPoseModifierParams &params)=0
Command Buffer. Pose data will not be available at this stage.
virtual bool Execute (const SAnimationPoseModifierParams &params)=0
virtual void Synchronize ()=0
virtual void GetMemoryUsage (ICrySizer *pSizer) const =0

Detailed Description

Example (Look-IK)
#include
// Example for how to make the character look at a specific position
void SetLookInverseKinematicsTarget(ICharacterInstance& character, const Vec3& targetWorldPosition)
{
// Query the pose blender look interface
if (IAnimationPoseBlenderDir* pPoseBlenderLook = character.GetISkeletonPose()->GetIPoseBlenderLook())
{
// Enable the Look-IK
pPoseBlenderLook->SetState(true);
// Make Look-IK operate on the second animation layer
pPoseBlenderLook->SetLayer(1);
// Indicate the position we want to look at
pPoseBlenderLook->SetTarget(targetWorldPosition);
}
}
Example (Aim-IK)
#include
// Example for how to make the character aim at a specific position
void SetAimInverseKinematicsTarget(ICharacterInstance& character, const Vec3& targetWorldPosition)
{
// Query the pose blender aim interface
if (IAnimationPoseBlenderDir* pPoseBlenderAim = character.GetISkeletonPose()->GetIPoseBlenderAim())
{
// Enable the Aim-IK
pPoseBlenderAim->SetState(true);
// Make Aim-IK operate on the second animation layer
pPoseBlenderAim->SetLayer(1);
// Indicate the position we want to aim at
pPoseBlenderAim->SetTarget(targetWorldPosition);
}
}