mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 03:44:02 +02:00
disable environment gravity when not set in menu
This commit is contained in:
parent
68b0e91630
commit
80ed8e7cf0
1 changed files with 2 additions and 0 deletions
|
@ -1382,6 +1382,8 @@ void MyAvatar::updateMotionBehaviorsFromMenu() {
|
|||
_motionBehaviors |= AVATAR_MOTION_OBEY_ENVIRONMENTAL_GRAVITY;
|
||||
// Environmental and Local gravities are incompatible. Environmental setting trumps local.
|
||||
_motionBehaviors &= ~AVATAR_MOTION_OBEY_LOCAL_GRAVITY;
|
||||
} else {
|
||||
_motionBehaviors &= ~AVATAR_MOTION_OBEY_ENVIRONMENTAL_GRAVITY;
|
||||
}
|
||||
if (! (_motionBehaviors & (AVATAR_MOTION_OBEY_ENVIRONMENTAL_GRAVITY | AVATAR_MOTION_OBEY_LOCAL_GRAVITY))) {
|
||||
setGravity(glm::vec3(0.0f));
|
||||
|
|
Loading…
Reference in a new issue