Drag[en]gine Script Module DragonScript  1.23
Dragengine.Scenery.ECComposeAnimator Class Reference

Composable animator for element class. More...

Inheritance diagram for Dragengine.Scenery.ECComposeAnimator:

Classes

class  Playback
 Playback support for elements. More...
 

Public Member Functions

AnimatorInstance createAnimatorInstance (Element element, StubElement stub)
 
AnimatorInstance createAnimatorInstance (Element element, StubElement stub, Component component)
 Initialize animator instance for element from stub. More...
 
Animator createMoveAnimator (Element element, StubElement stub, Component component)
 Create animator using animation and move. More...
 
Playback createPlayback (AnimatorInstance instance, StubElement stub)
 Create playback helper. More...
 
TSTriggerExpression createTriggerPlaying (Element element, StubElement stub)
 Create playing trigger expression from stub or null if not used. More...
 
TSTriggerExpression createTriggerPlaying (Element element, StubElement stub, String defaultValue)
 Create playing trigger expression from stub or null if not used. More...
 
ECPAnimation getAnimation ()
 Animation resource. More...
 
ECPAnimator getAnimator ()
 Animator resource. More...
 
ECPBoolean getLoopMove ()
 Loop animation move. More...
 
ECPString getMove ()
 Move name. More...
 
ECPString getPlaybackController ()
 Playback controller name. More...
 
ECPBoolean getPlaying ()
 Animation is playing. More...
 
ECPFloat getPlaySpeed ()
 Play speed. More...
 
String getPrefix ()
 Property prefix. More...
 
ECComposeAnimator new (ElementClass ownerClass, Loaders loaders)
 Create composable element class. More...
 
ECComposeAnimator new (ElementClass ownerClass, Loaders loaders, String prefix)
 Create composable element class. More...
 

Public Attributes

ECPAnimation pAnimation
 
ECPAnimator pAnimator
 
ECPBoolean pLoopMove
 
ECPString pMove
 
ECPString pPlaybackController
 
ECPBoolean pPlaying
 
ECPFloat pPlaySpeed
 
String pPrefix
 

Detailed Description

Composable animator for element class.

Provides animator support to element class without subclassing from a specific class. Sets the animator to use by an animator instance. Optionally an animation object can be defined overwriting the one used int he animator. The playback parameters influence the playback speed and if the animator is played back looping or once. Optionally an activate playback trigger can be used to switch playback on and off.

Member Function Documentation

◆ createAnimatorInstance() [1/2]

AnimatorInstance Dragengine.Scenery.ECComposeAnimator.createAnimatorInstance ( Element  element,
StubElement  stub 
)

◆ createAnimatorInstance() [2/2]

AnimatorInstance Dragengine.Scenery.ECComposeAnimator.createAnimatorInstance ( Element  element,
StubElement  stub,
Component  component 
)

Initialize animator instance for element from stub.

Version
1.19

Assigns the animator and animation to the instance. If at least one controller is present then the first controller is initialized as playback controller. If no animator is defined but animation and move is defined an animator is created with one controller and an animation rule playing back the move.

◆ createMoveAnimator()

Animator Dragengine.Scenery.ECComposeAnimator.createMoveAnimator ( Element  element,
StubElement  stub,
Component  component 
)

Create animator using animation and move.

Version
1.19

Creates animator is created with one controller and an animation rule playing back the move. Playback can be looping or not depending on getLoopMove(). If animation or move is null no animator is created and null is returned.

◆ createPlayback()

Playback Dragengine.Scenery.ECComposeAnimator.createPlayback ( AnimatorInstance  instance,
StubElement  stub 
)

Create playback helper.

◆ createTriggerPlaying() [1/2]

TSTriggerExpression Dragengine.Scenery.ECComposeAnimator.createTriggerPlaying ( Element  element,
StubElement  stub 
)

Create playing trigger expression from stub or null if not used.

◆ createTriggerPlaying() [2/2]

TSTriggerExpression Dragengine.Scenery.ECComposeAnimator.createTriggerPlaying ( Element  element,
StubElement  stub,
String  defaultValue 
)

Create playing trigger expression from stub or null if not used.

◆ getAnimation()

ECPAnimation Dragengine.Scenery.ECComposeAnimator.getAnimation ( )

Animation resource.

◆ getAnimator()

ECPAnimator Dragengine.Scenery.ECComposeAnimator.getAnimator ( )

Animator resource.

◆ getLoopMove()

ECPBoolean Dragengine.Scenery.ECComposeAnimator.getLoopMove ( )

Loop animation move.

Version
1.19

Used only if animator is not set and animation and move is set.

◆ getMove()

ECPString Dragengine.Scenery.ECComposeAnimator.getMove ( )

Move name.

Version
1.19

If animator is not set creates an animator playing back move. This can be used to play animation moves without needing to create an animator.

◆ getPlaybackController()

ECPString Dragengine.Scenery.ECComposeAnimator.getPlaybackController ( )

Playback controller name.

◆ getPlaying()

ECPBoolean Dragengine.Scenery.ECComposeAnimator.getPlaying ( )

Animation is playing.

◆ getPlaySpeed()

ECPFloat Dragengine.Scenery.ECComposeAnimator.getPlaySpeed ( )

Play speed.

◆ getPrefix()

String Dragengine.Scenery.ECComposeAnimator.getPrefix ( )

Property prefix.

◆ new() [1/2]

ECComposeAnimator Dragengine.Scenery.ECComposeAnimator.new ( ElementClass  ownerClass,
Loaders  loaders 
)

Create composable element class.

Adds all properties to ownerClass. If you do not want a property to be configurable using XML subclassing use ownerClass.removeProperty() to remove them.

◆ new() [2/2]

ECComposeAnimator Dragengine.Scenery.ECComposeAnimator.new ( ElementClass  ownerClass,
Loaders  loaders,
String  prefix 
)

Create composable element class.

Adds all properties to ownerClass. If you do not want a property to be configurable using XML subclassing use ownerClass.removeProperty() to remove them.

Member Data Documentation

◆ pAnimation

ECPAnimation Dragengine.Scenery.ECComposeAnimator.pAnimation

◆ pAnimator

ECPAnimator Dragengine.Scenery.ECComposeAnimator.pAnimator

◆ pLoopMove

ECPBoolean Dragengine.Scenery.ECComposeAnimator.pLoopMove

◆ pMove

ECPString Dragengine.Scenery.ECComposeAnimator.pMove

◆ pPlaybackController

ECPString Dragengine.Scenery.ECComposeAnimator.pPlaybackController

◆ pPlaying

ECPBoolean Dragengine.Scenery.ECComposeAnimator.pPlaying

◆ pPlaySpeed

ECPFloat Dragengine.Scenery.ECComposeAnimator.pPlaySpeed

◆ pPrefix

String Dragengine.Scenery.ECComposeAnimator.pPrefix

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