AnimEvent
@Deprecated public class AnimationEvent extends AbstractCinematicEvent
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
animationName
Deprecated.
|
protected float |
blendTime
Deprecated.
|
protected AnimChannel |
channel
Deprecated.
|
protected int |
channelIndex
Deprecated.
|
protected Cinematic |
cinematic
Deprecated.
|
protected Spatial |
model
Deprecated.
|
static java.lang.String |
MODEL_CHANNELS
Deprecated.
|
protected java.lang.String |
modelName
Deprecated.
|
static int |
SAVABLE_VERSION
Deprecated.
|
initialDuration, listeners, loopMode, playState, resuming, speed, time
Modifier | Constructor and Description |
---|---|
protected |
AnimationEvent()
Deprecated.
used for serialization don't call directly use one of the following
constructors
|
|
AnimationEvent(Spatial model,
java.lang.String animationName)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
float initialDuration)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
float initialDuration,
float blendTime)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
float initialDuration,
int channelIndex)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
float initialDuration,
LoopMode loopMode)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
float initialDuration,
LoopMode loopMode,
float blendTime)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
float initialDuration,
LoopMode loopMode,
int channelIndex)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
int channelIndex)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
LoopMode loopMode)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
LoopMode loopMode,
float blendTime)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
LoopMode loopMode,
int channelIndex)
Deprecated.
creates an animation event
|
|
AnimationEvent(Spatial model,
java.lang.String animationName,
LoopMode loopMode,
int channelIndex,
float blendTime)
Deprecated.
creates an animation event
|
Modifier and Type | Method and Description |
---|---|
void |
dispose()
Deprecated.
method called when an event is removed from a cinematic
this method should remove any reference to any external objects.
|
void |
forceStop()
Deprecated.
Implement this method if the event needs different handling when
stopped naturally (when the event reach its end),
or when it was force-stopped during playback.
|
void |
initEvent(Application app,
Cinematic cinematic)
Deprecated.
Initialize this event (called internally only).
|
void |
onPause()
Deprecated.
Implement this method with code that you want to execute when the event is paused.
|
void |
onPlay()
Deprecated.
Implement this method with code that you want to execute when the event is started.
|
void |
onStop()
Deprecated.
Implement this method with code that you want to execute when the event is stopped.
|
void |
onUpdate(float tpf)
Deprecated.
Implement this method with the code that you want to execute on update
(only called when the event is playing).
|
void |
read(JmeImporter im)
Deprecated.
Used for serialization only.
|
void |
setLoopMode(LoopMode loopMode)
Deprecated.
Sets the loopMode of the animation.
|
void |
setSpeed(float speed)
Deprecated.
Sets the speed of the animation.
|
void |
setTime(float time)
Deprecated.
Fast-forward the event to the given timestamp.
|
void |
write(JmeExporter ex)
Deprecated.
Used for serialization only.
|
addListener, getDuration, getInitialDuration, getLoopMode, getPlayState, getSpeed, getTime, internalUpdate, pause, play, removeListener, setInitialDuration, stop
public static final int SAVABLE_VERSION
public static final java.lang.String MODEL_CHANNELS
protected AnimChannel channel
protected java.lang.String animationName
protected Spatial model
protected java.lang.String modelName
protected float blendTime
protected int channelIndex
protected Cinematic cinematic
protected AnimationEvent()
public AnimationEvent(Spatial model, java.lang.String animationName)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playpublic AnimationEvent(Spatial model, java.lang.String animationName, float initialDuration)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playinitialDuration
- the initial duration of the eventpublic AnimationEvent(Spatial model, java.lang.String animationName, LoopMode loopMode)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playloopMode
- the loopModeLoopMode
public AnimationEvent(Spatial model, java.lang.String animationName, float initialDuration, LoopMode loopMode)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playinitialDuration
- the initial duration of the eventloopMode
- the loopModeLoopMode
public AnimationEvent(Spatial model, java.lang.String animationName, float initialDuration, float blendTime)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playinitialDuration
- the initial duration of the eventblendTime
- the time interval during which the animation will be blendedAnimChannel.setAnim(java.lang.String, float)
public AnimationEvent(Spatial model, java.lang.String animationName, LoopMode loopMode, float blendTime)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playloopMode
- the loopModeblendTime
- the time interval during which the animation will be blendedLoopMode
,
AnimChannel.setAnim(java.lang.String, float)
public AnimationEvent(Spatial model, java.lang.String animationName, float initialDuration, LoopMode loopMode, float blendTime)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playinitialDuration
- the initial duration of the eventloopMode
- the loopModeblendTime
- the time interval during which the animation will be blendedLoopMode
,
AnimChannel.setAnim(java.lang.String, float)
public AnimationEvent(Spatial model, java.lang.String animationName, LoopMode loopMode, int channelIndex)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playloopMode
- the loopModechannelIndex
- the index of the channel default is 0. Events on the
same channelIndex will use the same channel.LoopMode
public AnimationEvent(Spatial model, java.lang.String animationName, int channelIndex)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playchannelIndex
- the index of the channel default is 0. Events on the
same channelIndex will use the same channel.public AnimationEvent(Spatial model, java.lang.String animationName, LoopMode loopMode, int channelIndex, float blendTime)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playloopMode
- the desired mode (Loop/DontLoop/Cycle)channelIndex
- the index of the channel default is 0. Events on theblendTime
- the time interval during which the animation will be blended
same channelIndex will use the same channel.public AnimationEvent(Spatial model, java.lang.String animationName, float initialDuration, int channelIndex)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playinitialDuration
- the initial duration of the eventchannelIndex
- the index of the channel default is 0. Events on the
same channelIndex will use the same channel.public AnimationEvent(Spatial model, java.lang.String animationName, float initialDuration, LoopMode loopMode, int channelIndex)
model
- the model on which the animation will be playedanimationName
- the name of the animation to playinitialDuration
- the initial duration of the eventloopMode
- the loopModechannelIndex
- the index of the channel default is 0. Events on the
same channelIndex will use the same channel.LoopMode
public void initEvent(Application app, Cinematic cinematic)
AbstractCinematicEvent
initEvent
in interface CinematicEvent
initEvent
in class AbstractCinematicEvent
app
- ignoredcinematic
- ignoredpublic void setTime(float time)
AbstractCinematicEvent
setTime
in interface CinematicEvent
setTime
in class AbstractCinematicEvent
time
- the time to fast forward to.public void onPlay()
AbstractCinematicEvent
onPlay
in class AbstractCinematicEvent
public void setSpeed(float speed)
AbstractCinematicEvent
setSpeed
in interface CinematicEvent
setSpeed
in class AbstractCinematicEvent
speed
- the desired speedup factor (default=1)public void onUpdate(float tpf)
AbstractCinematicEvent
onUpdate
in class AbstractCinematicEvent
tpf
- time per framepublic void onStop()
AbstractCinematicEvent
onStop
in class AbstractCinematicEvent
public void forceStop()
AbstractCinematicEvent
forceStop
in interface CinematicEvent
forceStop
in class AbstractCinematicEvent
public void onPause()
AbstractCinematicEvent
onPause
in class AbstractCinematicEvent
public void setLoopMode(LoopMode loopMode)
AbstractCinematicEvent
setLoopMode
in interface CinematicEvent
setLoopMode
in class AbstractCinematicEvent
loopMode
- the desired mode (default=DontLoop)LoopMode
public void write(JmeExporter ex) throws java.io.IOException
AbstractCinematicEvent
write
in interface Savable
write
in class AbstractCinematicEvent
ex
- exporterjava.io.IOException
- from the exporterpublic void read(JmeImporter im) throws java.io.IOException
AbstractCinematicEvent
read
in interface Savable
read
in class AbstractCinematicEvent
im
- importerjava.io.IOException
- from the importerpublic void dispose()
CinematicEvent
dispose
in interface CinematicEvent
dispose
in class AbstractCinematicEvent