mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 03:44:02 +02:00
I believe what we really want to decay is the mouse pitch.
This commit is contained in:
parent
e97970d961
commit
9fa170494c
1 changed files with 2 additions and 2 deletions
|
@ -210,8 +210,8 @@ void MyAvatar::simulate(float deltaTime, Transmitter* transmitter) {
|
|||
// you start moving, but don't do this with an HMD like the Oculus.
|
||||
if (!OculusManager::isConnected()) {
|
||||
if (forwardAcceleration > ACCELERATION_PULL_THRESHOLD) {
|
||||
_head.setPitch(_head.getPitch() * (1.f - forwardAcceleration * ACCELERATION_PITCH_DECAY * deltaTime));
|
||||
_head.setYaw(_head.getYaw() * (1.f - forwardAcceleration * ACCELERATION_YAW_DECAY * deltaTime));
|
||||
_head.setMousePitch(_head.getMousePitch() * qMax(0.0f,
|
||||
(1.f - forwardAcceleration * ACCELERATION_PITCH_DECAY * deltaTime)));
|
||||
}
|
||||
} else if (fabsf(forwardAcceleration) > OCULUS_ACCELERATION_PULL_THRESHOLD
|
||||
&& fabs(_head.getYaw()) > OCULUS_YAW_OFFSET_THRESHOLD) {
|
||||
|
|
Loading…
Reference in a new issue