struct IAnimSequence : public _i_reference_target_t { const int kSequenceVersion = 3; enum EAnimSequenceFlags { eSeqFlags_PlayOnReset = BIT(0), eSeqFlags_OutOfRangeConstant = BIT(1), eSeqFlags_OutOfRangeLoop = BIT(2), eSeqFlags_CutScene = BIT(3), eSeqFlags_NoHUD = BIT(4), eSeqFlags_NoPlayer = BIT(5), eSeqFlags_16To9 = BIT(8), eSeqFlags_NoGameSounds = BIT(9), eSeqFlags_NoSeek = BIT(10), eSeqFlags_NoAbort = BIT(11), eSeqFlags_NoSpeed = BIT(13), eSeqFlags_CanWarpInFixedTime = BIT(14), eSeqFlags_EarlyMovieUpdate = BIT(15), eSeqFlags_LightAnimationSet = BIT(16), eSeqFlags_NoMPSyncingNeeded = BIT(17) }; };
IMovieSystem.h
Animation sequence, operates on animation nodes contained in it.
enum EAnimSequenceFlags { eSeqFlags_PlayOnReset = BIT(0), eSeqFlags_OutOfRangeConstant = BIT(1), eSeqFlags_OutOfRangeLoop = BIT(2), eSeqFlags_CutScene = BIT(3), eSeqFlags_NoHUD = BIT(4), eSeqFlags_NoPlayer = BIT(5), eSeqFlags_16To9 = BIT(8), eSeqFlags_NoGameSounds = BIT(9), eSeqFlags_NoSeek = BIT(10), eSeqFlags_NoAbort = BIT(11), eSeqFlags_NoSpeed = BIT(13), eSeqFlags_CanWarpInFixedTime = BIT(14), eSeqFlags_EarlyMovieUpdate = BIT(15), eSeqFlags_LightAnimationSet = BIT(16), eSeqFlags_NoMPSyncingNeeded = BIT(17) };
IMovieSystem.h
Members |
Description |
eSeqFlags_PlayOnReset = BIT(0) |
!< Start playing this sequence immediately after reset of movie system(Level load). |
eSeqFlags_OutOfRangeConstant = BIT(1) |
!< Constant Out-Of-Range,time continues normally past sequence time range. |
eSeqFlags_OutOfRangeLoop = BIT(2) |
!< Loop Out-Of-Range,time wraps back to the start of range when reaching end of range. |
eSeqFlags_CutScene = BIT(3) |
!< Cut scene sequence. |
eSeqFlags_NoHUD = BIT(4) |
!< Don`t display HUD |
eSeqFlags_NoPlayer = BIT(5) |
!< Disable input and drawing of player |
eSeqFlags_16To9 = BIT(8) |
!< 16:9 bars in sequence |
eSeqFlags_NoGameSounds = BIT(9) |
!< Suppress all game sounds. |
eSeqFlags_NoSeek = BIT(10) |
!< Cannot seek in sequence. |
eSeqFlags_NoAbort = BIT(11) |
!< Cutscene can not be aborted |
eSeqFlags_NoSpeed = BIT(13) |
!< Cannot modify sequence speed - TODO: add interface control if required |
eSeqFlags_CanWarpInFixedTime = BIT(14) |
!< Timewarping will work with a fixed time step. |
eSeqFlags_EarlyMovieUpdate = BIT(15) |
!< Turn the 'sys_earlyMovieUpdate' on during the sequence. |
eSeqFlags_LightAnimationSet = BIT(16) |
!< A special unique sequence for light animations |
eSeqFlags_NoMPSyncingNeeded = BIT(17) |
!< this sequence doesn't require MP net syncing |
const int kSequenceVersion = 3;
virtual void Activate() = 0;
Activate sequence by binding sequence animations to nodes. must be called prior animating sequence.
virtual bool AddNode(IAnimNode * node) = 0;
! Add animation node to sequence. ! @return True if node added, same node will not be added 2 times.
Adds/removes track events in sequence.
virtual bool AddTrackEvent(const char* szEvent) = 0;
virtual void AddTrackEventListener(ITrackEventListener * pListener) = 0;
! Track event listener
virtual void AdjustKeysToTimeRange(const Range & timeRange) = 0;
Move/Scale all keys in tracks from previous time range to new time range.
virtual void Animate(const SAnimContext & ec) = 0;
Evaluate animations of all nodes in sequence. Sequence must be activated before animating.
virtual void ClearTrackEvents() = 0;
virtual void CopyNodes(XmlNodeRef& xmlNode, IAnimNode** pSelectedNodes, uint32 count) = 0;
Copy some nodes of this sequence to XML.
virtual IAnimNode* CreateNode(EAnimNodeType nodeType) = 0;
Parameters |
Description |
EAnimNodeType nodeType |
Type of node, one of EAnimNodeType enums. |
Creates a new animation node with specified type.
virtual IAnimNode* CreateNode(XmlNodeRef node) = 0;
Parameters |
Description |
XmlNodeRef node |
Serialized form of node |
Creates a new animation node from serialized node XML.
virtual void Deactivate() = 0;
Deactivates sequence by unbinding sequence animations from nodes.
Finds node by name, can be slow. If the node belongs to a director, the director node also should be given since there can be multiple instances of the same node(i.e. the same name) across multiple director nodes.
virtual IAnimNode * GetActiveDirector() const = 0;
! Get the currently active director node, if any.
virtual int GetCutSceneFlags(const bool localFlags = false) const = 0;
! Get cutscene related animation sequence flags
virtual float GetFixedTimeStep() const = 0;
! Get the fixed time step for timewarping.
virtual int GetFlags() const = 0;
! Get animation sequence flags
virtual uint32 GetId() const = 0;
! Get the ID (unique in a level and consistent across renaming) of this sequence.
virtual void GetMemoryUsage(ICrySizer * pSizer) const = 0;
collect memory informations
virtual const char* GetName() const = 0;
! Get the name of this sequence. (ex. "Intro" in the same case as above)
virtual IAnimNode* GetNode(int index) const = 0;
! Get animation node at specified index.
virtual int GetNodeCount() const = 0;
! Return number of animation nodes in sequence.
virtual IAnimSequenceOwner* GetOwner() const = 0;
virtual const IAnimSequence* GetParentSequence() const = 0;
! Get parent animation sequence
virtual Range GetTimeRange() = 0;
! Get time range of this sequence.
Gets the specified track event in the sequence.
virtual char const* GetTrackEvent(int iIndex) const = 0;
Gets the track events in the sequence.
virtual int GetTrackEventsCount() const = 0;
virtual IAnimStringTable* GetTrackEventStringTable() = 0;
virtual bool IsActivated() const = 0;
Check if sequence is activated
virtual bool IsAncestorOf(const IAnimSequence * pSequence) const = 0;
! Check whether this sequence has the given sequence as a descendant through one of its sequence tracks.
virtual bool IsPaused() const = 0;
Called to check if sequence is paused.
virtual bool MoveDownTrackEvent(const char* szEvent) = 0;
virtual bool MoveUpTrackEvent(const char* szEvent) = 0;
virtual void PasteNodes(const XmlNodeRef& xmlNode, IAnimNode * pParent) = 0;
Paste nodes given by the XML to this sequence.
virtual void Pause() = 0;
Called to pause sequence.
virtual void PrecacheData(float startTime = 0.0f) = 0;
Pre-caches data associated with this anim sequence.
virtual void RemoveAll() = 0;
! Remove all nodes from sequence.
virtual void RemoveNode(IAnimNode * node) = 0;
! Remove animation node from sequence.
virtual bool RemoveTrackEvent(const char* szEvent) = 0;
virtual void RemoveTrackEventListener(ITrackEventListener * pListener) = 0;
virtual bool RenameTrackEvent(const char* szEvent, const char* szNewEvent) = 0;
virtual void Render() = 0;
Render function call for some special node.
Reorders the array of nodes, so the specified node is placed after or before the given pivot node depending on the parameter 'next'.
virtual void Reset(bool bSeekToStart) = 0;
! Resets the sequence
virtual void ResetHard() = 0;
! This can have more time-consuming tasks performed additional to tasks of the usual 'Reset()' method.
virtual void Resume() = 0;
Called to resume sequence.
virtual void Serialize(XmlNodeRef & xmlNode, bool bLoading, bool bLoadEmptyTracks = true, uint32 overrideId = 0, bool bUndo = false) = 0;
Serialize this sequence to XML.
virtual void SetActiveDirector(IAnimNode * pDirectorNode) = 0;
! Set the currently active director node.
virtual void SetFixedTimeStep(float dt) = 0;
! Set the fixed time step for timewarping.
virtual void SetFlags(int flags) = 0;
! Set animation sequence flags
virtual void SetName(const char * name) = 0;
! Set the name of this sequence. (ex. "Intro" in the same case as above)
virtual void SetOwner(IAnimSequenceOwner * pOwner) = 0;
virtual void SetParentSequence(IAnimSequence * pParentSequence) = 0;
! Set parent animation sequence
virtual void SetTimeRange(Range timeRange) = 0;
! Set time range of this sequence.
virtual void StillUpdate() = 0;
Update sequence while not playing animation.
Called to trigger a track event.
virtual void TriggerTrackEvent(const char* event, const char* param = NULL) = 0;