Fix for HMD mode flying

In HMD mode you should fly/move in the direction you are looking.
This commit is contained in:
Anthony J. Thibault 2019-10-15 18:22:42 -07:00
parent f7862a0556
commit 288f9bfb16

View file

@ -2719,7 +2719,7 @@ void MyAvatar::updateMotors() {
if (_characterController.getState() == CharacterController::State::Hover ||
_characterController.computeCollisionMask() == BULLET_COLLISION_MASK_COLLISIONLESS) {
CameraMode mode = qApp->getCamera().getMode();
if (mode == CAMERA_MODE_FIRST_PERSON || mode == CAMERA_MODE_LOOK_AT || mode == CAMERA_MODE_SELFIE) {
if (!qApp->isHMDMode() && (mode == CAMERA_MODE_FIRST_PERSON || mode == CAMERA_MODE_LOOK_AT || mode == CAMERA_MODE_SELFIE)) {
motorRotation = getLookAtRotation();
} else {
motorRotation = getMyHead()->getHeadOrientation();