: entity(entity)
, pitch(0)
, yaw(0) {
+ entity.Ref();
+}
+FPSController::~FPSController() {
+ entity.UnRef();
}
void FPSController::Update(int dt) noexcept {
- entity.Rotation(glm::quat(glm::vec3(pitch, yaw, 0.0f)));
+ entity.Orientation(glm::quat(glm::vec3(pitch, yaw, 0.0f)));
entity.Velocity(glm::rotateY(velocity, yaw));
}