|
Vulkan Schnee 0.0.1
High-performance rendering engine
|
A scene component has a transform. More...
#include <SceneComponent.h>
Public Member Functions | |
| SceneComponent (Scene *scene) | |
| SceneComponent (Scene *scene, const entt::entity &parent, const glm::mat4 &transform) | |
| SceneComponent (Scene *scene, const entt::entity &parent, const glm::vec3 &position) | |
| SceneComponent (Scene *scene, const entt::entity &parent, const glm::vec3 &position, const glm::quat &rotation) | |
| SceneComponent (Scene *scene, const entt::entity &parent, const glm::vec3 &position, const glm::vec3 &rotation) | |
| SceneComponent (Scene *scene, const entt::entity &parent, const glm::vec3 &position, const glm::quat &rotation, const glm::vec3 &scale) | |
| Public Member Functions inherited from EngineCore::LogicComponent | |
| LogicComponent (Scene *owningScene) | |
| virtual | ~LogicComponent ()=default |
| virtual void | beginPlay () |
| Called when the component is added to the scene or the game starts. | |
| virtual void | tick (double deltaTime) |
| Called every frame if ticking is enabled. | |
| virtual void | endPlay () |
| Called when the component is removed or the game ends. | |
| bool | canTick () const |
| Checks if the component is currently set to tick. | |
| void | setCanTick (bool enable) |
| Enables or disables ticking for this component. | |
| Entity * | getOwningEntity () const |
| Gets the entity this component belongs to. | |
Protected Attributes | |
| entt::entity | component = entt::null |
| Stores the data. | |
| Ecs::LocalTransform * | transformComponent = nullptr |
| Ecs::Parent * | parentComponent = nullptr |
Private Member Functions | |
| void | setParent (const entt::entity &parent) |
Additional Inherited Members | |
| Static Public Attributes inherited from EngineCore::LogicComponent | |
| static constexpr bool | IsUnique = false |
| Defines whether multiple instances of this component can exist on the same entity. Defaults to false (multiple allowed). Override in derived classes with static constexpr bool IsUnique = true; if needed. | |
| Protected Member Functions inherited from EngineCore::LogicComponent | |
| Scene * | getScene () const |
| Gets the scene this component belongs to. | |
| SceneManager * | getSceneManager () const |
| Helper to get the SceneManager from the owning scene. | |
|
explicit |
Definition at line 10 of file SceneComponent.cpp.
References EngineCore::LogicComponent::LogicComponent(), and EngineCore::LogicComponent::scene.
|
explicit |
Definition at line 12 of file SceneComponent.cpp.
References component, Ecs::RegistryManager::get(), EngineCore::LogicComponent::LogicComponent(), EngineCore::LogicComponent::scene, setParent(), and transformComponent.
|
explicit |
Definition at line 24 of file SceneComponent.cpp.
References component, Ecs::RegistryManager::get(), EngineCore::LogicComponent::LogicComponent(), EngineCore::LogicComponent::scene, setParent(), Ecs::TransformOperators::setPosition(), and transformComponent.
|
explicit |
Definition at line 36 of file SceneComponent.cpp.
References component, Ecs::RegistryManager::get(), EngineCore::LogicComponent::LogicComponent(), EngineCore::LogicComponent::scene, setParent(), Ecs::TransformOperators::setPosition(), Ecs::TransformOperators::setRotation(), and transformComponent.
|
explicit |
Definition at line 50 of file SceneComponent.cpp.
References component, Ecs::RegistryManager::get(), EngineCore::LogicComponent::LogicComponent(), EngineCore::LogicComponent::scene, setParent(), Ecs::TransformOperators::setPosition(), Ecs::TransformOperators::setRotation(), and transformComponent.
|
explicit |
Definition at line 64 of file SceneComponent.cpp.
References component, Ecs::RegistryManager::get(), EngineCore::LogicComponent::LogicComponent(), EngineCore::LogicComponent::scene, setParent(), Ecs::TransformOperators::setPosition(), Ecs::TransformOperators::setRotation(), Ecs::TransformOperators::setScale(), and transformComponent.
|
private |
Definition at line 83 of file SceneComponent.cpp.
References Ecs::RegistryManager::get(), and parentComponent.
Referenced by SceneComponent(), SceneComponent(), SceneComponent(), SceneComponent(), and SceneComponent().
|
protected |
Stores the data.
Definition at line 44 of file SceneComponent.h.
Referenced by SceneComponent(), SceneComponent(), SceneComponent(), SceneComponent(), and SceneComponent().
|
protected |
Definition at line 47 of file SceneComponent.h.
Referenced by setParent().
|
protected |
Definition at line 46 of file SceneComponent.h.
Referenced by SceneComponent(), SceneComponent(), SceneComponent(), SceneComponent(), and SceneComponent().