mirror of
https://github.com/overte-org/overte.git
synced 2025-04-21 19:04:32 +02:00
space out if
This commit is contained in:
parent
4738fc888b
commit
a1b556d6a2
1 changed files with 4 additions and 2 deletions
|
@ -313,8 +313,10 @@ void Application::paintGL() {
|
|||
// Take a look at whether we are inside head, don't render it if so.
|
||||
const float HEAD_RENDER_DISTANCE = 0.5;
|
||||
glm::vec3 distanceToHead(_myCamera.getPosition() - _myAvatar.getSpringyHeadPosition());
|
||||
if (glm::length(distanceToHead) < HEAD_RENDER_DISTANCE) { _myAvatar.setDisplayingHead(false); }
|
||||
|
||||
|
||||
if (glm::length(distanceToHead) < HEAD_RENDER_DISTANCE) {
|
||||
_myAvatar.setDisplayingHead(false);
|
||||
}
|
||||
} else if (_myCamera.getMode() == CAMERA_MODE_THIRD_PERSON) {
|
||||
_myCamera.setTargetPosition(_myAvatar.getHeadPosition());
|
||||
_myCamera.setTargetRotation(_myAvatar.getBodyYaw(),
|
||||
|
|
Loading…
Reference in a new issue