aboutsummaryrefslogtreecommitdiff
path: root/src/camera.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/camera.cpp')
-rw-r--r--src/camera.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/camera.cpp b/src/camera.cpp
index 316a3f70a..4b0f968a4 100644
--- a/src/camera.cpp
+++ b/src/camera.cpp
@@ -151,8 +151,7 @@ void Camera::update(LocalPlayer* player, f32 frametime, v2u32 screensize)
m_playernode->updateAbsolutePosition();
// Set head node transformation
- v3f eye_offset = player->getEyePosition() - player->getPosition();
- m_headnode->setPosition(eye_offset);
+ m_headnode->setPosition(player->getEyeOffset());
m_headnode->setRotation(v3f(player->getPitch(), 0, 0));
m_headnode->updateAbsolutePosition();