Public Member Functions | |
| void | Blend (const int animID, float speed, float blend, int flags) |
| EnumAnimStateFlags. | |
| void | Blend (const int animID, float speed, float blend, int flags, const int frame, const bool runActions=true, const bool noSoundActions=false) |
| EnumAnimStateFlags. Blends the animation to the frame while optionally running all previous actions. | |
| void | Set (const int animID, float speed, int flags) |
| EnumAnimStateFlags. | |
| void | Set (const int animID, float speed, int flags, const int frame, const bool runActions=true, const bool noSoundActions=false) |
| EnumAnimStateFlags. Sets the animation to the frame while optionally running all previous actions. | |
| const int | CurrentFrame () |
| current frame playing for the current animation. Must have an animation action keyframe for this to work, otherwise use TrackFrame() instead. This should be named more like last frame an action was checked to execute. | |
| const int | NumFrames () |
| number of frames in this animation. Returns -1 if no animation set. | |
| const int | NumNodes () |
| number of nodes in this animation. Returns -1 if no animation set. | |
| const float | PlayTime () |
| increases by GAME_DELTA_TIME if not stopped or paused. | |
| const float | TrackTime () |
| time from 0(on first frame) to 1(on last frame). | |
| bool | IsPlaying (const int animID) |
| Returns true if current animations ID is animID and the animation is not stopped. | |
| bool | CheckAnimID (const int animID) |
| checks if animID exists | |
| const int | PlayingID () const |
| the current animations ID | |
| void | Stop () |
| flags |= ANF_STOPPED; flags &= ~ANF_LOOP; | |
| void | Pause () |
| flags |= ANF_PAUSED; | |
| void | Resume () |
| flags &= ~ANF_PAUSED; | |
| const bool | Stopped () const |
| (flags & ANF_STOPPED) != 0 | |
| const bool | Blending () const |
| (flags & ANF_BLEND) != 0 | |
| const bool | Looping () const |
| (flags & ANF_LOOP) != 0 | |
| const bool | CycleCompleted () const |
| (flags & ANF_CYCLECOMPLETED) != 0 | |
| void | ChangeSpeed (const float speed) |
| Scales speed of the current animation where 1.0 = 15fps and 4.0 = 60fps. | |
| void | SetLastFrame (const bool execActions=false) |
| if execActions is true, runs all key frame actions in the animation except Footstep(55) and PlaySound(248). applies the stop flag (flags |= ANF_STOPPED). | |
| void | SetPlayTime (const float time) |
| The total time in seconds this animation has been playing. | |
| void | SetTrackTime (const float time) |
| 0.0(first frame) to 1.0(last frame) | |
| const int | TrackFrame (void) const |
| current frame playing for the current animation. | |
| const int | TrackNextFrame (void) const |
| next frame to play for the current animation. | |
| kQuat | GetRotation (const int animID, int nodeNum, int frame) |
| kVec3 | GetOrigin (const int animID, int nodeNum, int frame) |
| const int | GetAnimNumFrames (const int animID) |
| const int | LoopFrame () |
| The frame the animation loops back to when it reaches the last frame. Returns -1 if no animation set. | |
Public Attributes | |
| int | flags |
| EnumAnimStateFlags. | |
| float | baseOffset |
| is somewhat the Z position of the root node. It's calculated as follows whenever the root motion is updated (ANF_ROOTMOTION must be set). | |
| kVec3 | rootMotion |
| the move direction of the root node from the prev frame to the current frame. | |
Definition at line 1160 of file t1_scriptAPI.cpp.
| void kAnimState::Blend | ( | const int | animID, |
| float | speed, | ||
| float | blend, | ||
| int | flags ) |
| void kAnimState::Blend | ( | const int | animID, |
| float | speed, | ||
| float | blend, | ||
| int | flags, | ||
| const int | frame, | ||
| const bool | runActions = true, | ||
| const bool | noSoundActions = false ) |
EnumAnimStateFlags. Blends the animation to the frame while optionally running all previous actions.
| const bool kAnimState::Blending | ( | ) | const |
(flags & ANF_BLEND) != 0
| void kAnimState::ChangeSpeed | ( | const float | speed | ) |
Scales speed of the current animation where 1.0 = 15fps and 4.0 = 60fps.
| bool kAnimState::CheckAnimID | ( | const int | animID | ) |
checks if animID exists
| const int kAnimState::CurrentFrame | ( | ) |
current frame playing for the current animation. Must have an animation action keyframe for this to work, otherwise use TrackFrame() instead. This should be named more like last frame an action was checked to execute.
| const bool kAnimState::CycleCompleted | ( | ) | const |
(flags & ANF_CYCLECOMPLETED) != 0
| const int kAnimState::GetAnimNumFrames | ( | const int | animID | ) |
| kVec3 kAnimState::GetOrigin | ( | const int | animID, |
| int | nodeNum, | ||
| int | frame ) |
| kQuat kAnimState::GetRotation | ( | const int | animID, |
| int | nodeNum, | ||
| int | frame ) |
| bool kAnimState::IsPlaying | ( | const int | animID | ) |
Returns true if current animations ID is animID and the animation is not stopped.
| const int kAnimState::LoopFrame | ( | ) |
The frame the animation loops back to when it reaches the last frame. Returns -1 if no animation set.
| const bool kAnimState::Looping | ( | ) | const |
(flags & ANF_LOOP) != 0
| const int kAnimState::NumFrames | ( | ) |
number of frames in this animation. Returns -1 if no animation set.
| const int kAnimState::NumNodes | ( | ) |
number of nodes in this animation. Returns -1 if no animation set.
| void kAnimState::Pause | ( | ) |
flags |= ANF_PAUSED;
| const int kAnimState::PlayingID | ( | ) | const |
the current animations ID
| const float kAnimState::PlayTime | ( | ) |
increases by GAME_DELTA_TIME if not stopped or paused.
| void kAnimState::Resume | ( | ) |
flags &= ~ANF_PAUSED;
| void kAnimState::Set | ( | const int | animID, |
| float | speed, | ||
| int | flags ) |
| void kAnimState::Set | ( | const int | animID, |
| float | speed, | ||
| int | flags, | ||
| const int | frame, | ||
| const bool | runActions = true, | ||
| const bool | noSoundActions = false ) |
EnumAnimStateFlags. Sets the animation to the frame while optionally running all previous actions.
| void kAnimState::SetLastFrame | ( | const bool | execActions = false | ) |
if execActions is true, runs all key frame actions in the animation except Footstep(55) and PlaySound(248). applies the stop flag (flags |= ANF_STOPPED).
| void kAnimState::SetPlayTime | ( | const float | time | ) |
The total time in seconds this animation has been playing.
| void kAnimState::SetTrackTime | ( | const float | time | ) |
0.0(first frame) to 1.0(last frame)
| void kAnimState::Stop | ( | ) |
flags |= ANF_STOPPED; flags &= ~ANF_LOOP;
| const bool kAnimState::Stopped | ( | ) | const |
(flags & ANF_STOPPED) != 0
| const int kAnimState::TrackFrame | ( | void | ) | const |
current frame playing for the current animation.
| const int kAnimState::TrackNextFrame | ( | void | ) | const |
next frame to play for the current animation.
| const float kAnimState::TrackTime | ( | ) |
time from 0(on first frame) to 1(on last frame).
| float kAnimState::baseOffset |
is somewhat the Z position of the root node. It's calculated as follows whenever the root motion is updated (ANF_ROOTMOTION must be set).
Definition at line 1205 of file t1_scriptAPI.cpp.
| int kAnimState::flags |
Definition at line 1192 of file t1_scriptAPI.cpp.
| kVec3 kAnimState::rootMotion |
the move direction of the root node from the prev frame to the current frame.
Definition at line 1206 of file t1_scriptAPI.cpp.