TopDown Engine v4.3
MoreMountains.Feedbacks.MMF_AnimatorPlayState Class Reference

A feedback used to play the specified state on the target Animator, either in normalized or fixed time. More...

Inheritance diagram for MoreMountains.Feedbacks.MMF_AnimatorPlayState:
MoreMountains.Feedbacks.MMF_Feedback

Public Types

enum  TriggerModes { SetTrigger , ResetTrigger }
 the possible modes that pilot triggers
More...
 
enum  ValueModes { None , Constant , Random , Incremental }
 the possible ways to set a value More...
 
enum  Modes { NormalizedTime , FixedTime }
 

Public Attributes

Animator BoundAnimator
 the animator whose parameters you want to update More...
 
List< Animator > ExtraBoundAnimators
 the list of extra animators whose parameters you want to update More...
 
float DeclaredDuration = 0f
 the duration for the player to consider. This won't impact your animation, but is a way to communicate to the MMF Player the duration of this feedback. Usually you'll want it to match your actual animation, and setting it can be useful to have this feedback work with holding pauses. More...
 
string StateName
 The name of the state to play on the target animator. More...
 
Modes Mode = Modes.NormalizedTime
 Whether to play the state at a normalized time (between 0 and 1) or a fixed time (in seconds) More...
 
float NormalizedTime = 0f
 The time offset between zero and one at which to play the specified state. More...
 
float FixedTime = 0f
 The time offset (in seconds) at which to play the specified state. More...
 
int LayerIndex = -1
 The layer index. If layer is -1, it plays the first state with the given state name or hash. More...
 
bool SetLayerWeight = false
 whether or not to set layer weights on the specified layer when playing this feedback More...
 
int TargetLayerIndex = 1
 the index of the layer to target when changing layer weights More...
 
float NewWeight = 0.5f
 the new weight to set on the target animator layer More...
 

Static Public Attributes

static bool FeedbackTypeAuthorized = true
 a static bool used to disable all feedbacks of this type at once More...
 

Protected Member Functions

override void AutomateTargetAcquisition ()
 A method meant to be implemented per feedback letting you specify what happens (usually setting a target) More...
 
override void CustomInitialization (MMF_Player owner)
 Custom Init More...
 
override void CustomPlayFeedback (Vector3 position, float feedbacksIntensity=1.0f)
 On Play, checks if an animator is bound and plays the specified state More...
 
virtual void PlayState (Animator targetAnimator, float intensityMultiplier)
 Plays the specified state on the target animator More...
 
override void CustomStopFeedback (Vector3 position, float feedbacksIntensity=1.0f)
 On stop, we do nothing More...
 

Protected Attributes

int _targetParameter
 

Properties

override float FeedbackDuration [getset]
 sets the inspector color for this feedback More...
 
override bool HasRandomness [get]
 
override bool HasAutomatedTargetAcquisition [get]
 

Additional Inherited Members

Detailed Description

A feedback used to play the specified state on the target Animator, either in normalized or fixed time.

Member Enumeration Documentation

◆ Modes

Enumerator
NormalizedTime 
FixedTime 

◆ TriggerModes

the possible modes that pilot triggers

Enumerator
SetTrigger 
ResetTrigger 

◆ ValueModes

the possible ways to set a value

Enumerator
None 
Constant 
Random 
Incremental 

Member Function Documentation

◆ AutomateTargetAcquisition()

override void MoreMountains.Feedbacks.MMF_AnimatorPlayState.AutomateTargetAcquisition ( )
protectedvirtual

A method meant to be implemented per feedback letting you specify what happens (usually setting a target)

Reimplemented from MoreMountains.Feedbacks.MMF_Feedback.

◆ CustomInitialization()

override void MoreMountains.Feedbacks.MMF_AnimatorPlayState.CustomInitialization ( MMF_Player  owner)
protectedvirtual

Custom Init

Parameters
owner

Reimplemented from MoreMountains.Feedbacks.MMF_Feedback.

◆ CustomPlayFeedback()

override void MoreMountains.Feedbacks.MMF_AnimatorPlayState.CustomPlayFeedback ( Vector3  position,
float  feedbacksIntensity = 1.0f 
)
protectedvirtual

On Play, checks if an animator is bound and plays the specified state

Parameters
position
feedbacksIntensity

Implements MoreMountains.Feedbacks.MMF_Feedback.

◆ CustomStopFeedback()

override void MoreMountains.Feedbacks.MMF_AnimatorPlayState.CustomStopFeedback ( Vector3  position,
float  feedbacksIntensity = 1.0f 
)
protectedvirtual

On stop, we do nothing

Parameters
position
feedbacksIntensity

Reimplemented from MoreMountains.Feedbacks.MMF_Feedback.

◆ PlayState()

virtual void MoreMountains.Feedbacks.MMF_AnimatorPlayState.PlayState ( Animator  targetAnimator,
float  intensityMultiplier 
)
protectedvirtual

Plays the specified state on the target animator

Parameters
targetAnimator
intensityMultiplier

Member Data Documentation

◆ _targetParameter

int MoreMountains.Feedbacks.MMF_AnimatorPlayState._targetParameter
protected

◆ BoundAnimator

Animator MoreMountains.Feedbacks.MMF_AnimatorPlayState.BoundAnimator

the animator whose parameters you want to update

◆ DeclaredDuration

float MoreMountains.Feedbacks.MMF_AnimatorPlayState.DeclaredDuration = 0f

the duration for the player to consider. This won't impact your animation, but is a way to communicate to the MMF Player the duration of this feedback. Usually you'll want it to match your actual animation, and setting it can be useful to have this feedback work with holding pauses.

◆ ExtraBoundAnimators

List<Animator> MoreMountains.Feedbacks.MMF_AnimatorPlayState.ExtraBoundAnimators

the list of extra animators whose parameters you want to update

◆ FeedbackTypeAuthorized

bool MoreMountains.Feedbacks.MMF_AnimatorPlayState.FeedbackTypeAuthorized = true
static

a static bool used to disable all feedbacks of this type at once

◆ FixedTime

float MoreMountains.Feedbacks.MMF_AnimatorPlayState.FixedTime = 0f

The time offset (in seconds) at which to play the specified state.

◆ LayerIndex

int MoreMountains.Feedbacks.MMF_AnimatorPlayState.LayerIndex = -1

The layer index. If layer is -1, it plays the first state with the given state name or hash.

◆ Mode

Modes MoreMountains.Feedbacks.MMF_AnimatorPlayState.Mode = Modes.NormalizedTime

Whether to play the state at a normalized time (between 0 and 1) or a fixed time (in seconds)

◆ NewWeight

float MoreMountains.Feedbacks.MMF_AnimatorPlayState.NewWeight = 0.5f

the new weight to set on the target animator layer

◆ NormalizedTime

float MoreMountains.Feedbacks.MMF_AnimatorPlayState.NormalizedTime = 0f

The time offset between zero and one at which to play the specified state.

◆ SetLayerWeight

bool MoreMountains.Feedbacks.MMF_AnimatorPlayState.SetLayerWeight = false

whether or not to set layer weights on the specified layer when playing this feedback

◆ StateName

string MoreMountains.Feedbacks.MMF_AnimatorPlayState.StateName

The name of the state to play on the target animator.

◆ TargetLayerIndex

int MoreMountains.Feedbacks.MMF_AnimatorPlayState.TargetLayerIndex = 1

the index of the layer to target when changing layer weights

Property Documentation

◆ FeedbackDuration

override float MoreMountains.Feedbacks.MMF_AnimatorPlayState.FeedbackDuration
getset

sets the inspector color for this feedback

the duration of this feedback is the declared duration

◆ HasAutomatedTargetAcquisition

override bool MoreMountains.Feedbacks.MMF_AnimatorPlayState.HasAutomatedTargetAcquisition
get

◆ HasRandomness

override bool MoreMountains.Feedbacks.MMF_AnimatorPlayState.HasRandomness
get

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