|
|
@@ -47,7 +47,8 @@ struct AnimationControl
|
|
|
setTime_(0),
|
|
|
setWeight_(0),
|
|
|
setTimeRev_(0),
|
|
|
- setWeightRev_(0)
|
|
|
+ setWeightRev_(0),
|
|
|
+ removeOnCompletion_(true)
|
|
|
{
|
|
|
}
|
|
|
|
|
|
@@ -75,6 +76,8 @@ struct AnimationControl
|
|
|
unsigned char setTimeRev_;
|
|
|
/// Set weight command revision.
|
|
|
unsigned char setWeightRev_;
|
|
|
+ /// Sets whether this should automatically be removed when it finishes playing.
|
|
|
+ bool removeOnCompletion_;
|
|
|
};
|
|
|
|
|
|
/// %Component that drives an AnimatedModel's animations.
|
|
|
@@ -124,6 +127,8 @@ public:
|
|
|
bool SetSpeed(const String& name, float speed);
|
|
|
/// Set animation autofade at end (non-looped animations only.) Zero time disables. Return true on success.
|
|
|
bool SetAutoFade(const String& name, float fadeOutTime);
|
|
|
+ /// Set whether an animation auto-removes on completion
|
|
|
+ bool SetRemoveOnCompletion(const String& name, bool removeOnCompletion);
|
|
|
|
|
|
/// Return whether an animation is active. Note that non-looping animations that are being clamped at the end also return true.
|
|
|
bool IsPlaying(const String& name) const;
|