2#include "Engine/Component/LogicComponent.h"
3#include "Engine/World/SceneGraph.h"
41 std::shared_ptr<Entities::SceneNode> sceneNode,
52 void tick(
double deltaTime)
override;
Logic(Entities::Scene *owningScene)
Constructs a logic component owned by a scene.
void setMoveSpeed(float speed)
Sets the horizontal movement speed in units per second.
void beginPlay() override
Called when the component is added to the scene or the game starts.
void endPlay() override
Called when the component is removed or the game ends.
glm::vec3 getHeadsetForwardXZ() const
~VrMovement() override=default
Destroys the VR movement component.
static constexpr const char * ComponentName
Component registry name.
static constexpr bool IsUnique
This component type is unique per actor.
VrMovement(Entities::Scene *owningScene, std::shared_ptr< Entities::SceneNode > sceneNode, Rendering::Headset *headset, Input::XrInputHandler *inputHandler)
Constructs the VR movement component.
void setDeadZone(float deadZone)
Sets the dead zone for thumbstick input (0.0 to 1.0)
float getDeadZone() const
Gets the thumbstick dead zone.
Input::XrInputHandler * inputHandler_
void setVerticalSpeed(float speed)
Sets the vertical movement speed in units per second.
std::shared_ptr< Entities::SceneNode > sceneNode_
Rendering::Headset * headset_
void tick(double deltaTime) override
Called every frame if ticking is enabled.
float getMoveSpeed() const
Gets the horizontal movement speed in units per second.
float getVerticalSpeed() const
Gets the vertical movement speed in units per second.
Owns scene entities, actor lifetime, and the scene graph root.
Owns the OpenXR session, XR swapchain, eye transforms, and per-frame XR submission state.