Class AnimatedModelSpaceComponent
Defined in File AnimatedModelSpaceComponent.h
Inheritance Relationships
Base Types
public csp::multiplayer::ComponentBase
(Class ComponentBase)public csp::multiplayer::ITransformComponent
(Class ITransformComponent)public csp::multiplayer::IVisibleComponent
(Class IVisibleComponent)public csp::multiplayer::IExternalResourceComponent
(Class IExternalResourceComponent)public csp::multiplayer::IThirdPartyComponentRef
(Class IThirdPartyComponentRef)public csp::multiplayer::IShadowCasterComponent
(Class IShadowCasterComponent)
Class Documentation
-
class AnimatedModelSpaceComponent : public csp::multiplayer::ComponentBase, public csp::multiplayer::ITransformComponent, public csp::multiplayer::IVisibleComponent, public csp::multiplayer::IExternalResourceComponent, public csp::multiplayer::IThirdPartyComponentRef, public csp::multiplayer::IShadowCasterComponent
Adds animated skeletal meshes to a SpaceEntity.
These are used for objects that need to move or act within the space, such as characters or animated props. This component makes it possible to play, pause, or loop animations.
Public Functions
-
AnimatedModelSpaceComponent(SpaceEntity *Parent)
Constructs the animated model space component, and associates it with the specified Parent space entity.
- Parameters
Parent – The Space entity that owns this component.
-
virtual const csp::common::String &GetExternalResourceAssetId() const override
Gets the ID for the asset used to store external data for this component.
- Returns
csp::common::String : The asset ID.
-
virtual void SetExternalResourceAssetId(const csp::common::String &Value) override
Sets the ID for the asset used to store external data for this component.
- Parameters
InValue – csp::common::String : The new value.
-
virtual const csp::common::String &GetExternalResourceAssetCollectionId() const override
Gets the ID of the asset collection associated with this component.
Note
To retrieve this component’s animated asset, both the Asset ID and the Asset Collection ID are required.
- Returns
The ID of the asset collection associated with this component.
-
virtual void SetExternalResourceAssetCollectionId(const csp::common::String &Value) override
Sets the ID of the asset collection associated with this component.
Note
To retrieve this component’s animated asset, both the Asset ID and the Asset Collection ID are required.
- Parameters
Value – The ID of the asset collection associated with this component.
-
bool GetIsLoopPlayback() const
Checks if the animation of this animated model is in loop.
- Returns
True if the animation of this animated model loops (i.e. restarts from the beginning on end), false otherwise.
-
void SetIsLoopPlayback(bool Value)
Establishes if the animation of this animated model is in loop.
- Parameters
Value – True if the animation of this animated model will loop (i.e. restarts from the beginning on end), false otherwise.
-
bool GetIsPlaying() const
Checks if the animation of this animated model is playing.
- Returns
True if the animation of this animated is playing, false otherwise.
-
void SetIsPlaying(bool Value)
Establishes if the animation of this animated model is playing.
- Parameters
Value – True if the animation of this animated model is playing, false otherwise.
-
int64_t GetAnimationIndex() const
Gets the index of the currently active animation.
- Returns
The index of the currently active animation.
-
void SetAnimationIndex(int64_t Value)
Sets the index of the currently active animation.
- Returns
The index of the currently active animation.
-
csp::common::Map<csp::common::String, csp::common::String> GetMaterialOverrides() const
Gets the material overrides of this component.
Should be in the format: Key = Path to the model Value = The material id
- Returns
The material overrides on this component.
-
AnimatedModelSpaceComponent(SpaceEntity *Parent)