]> git.lizzy.rs Git - dragonfireclient.git/blobdiff - src/client/localplayer.cpp
Merge branch 'master' of https://github.com/minetest/minetest
[dragonfireclient.git] / src / client / localplayer.cpp
index c4d9b98457d6c10574b5e7aec07e964c2db52d60..aeccc5c7dc4de54531d0fdede13567ad1089865e 100644 (file)
@@ -450,16 +450,6 @@ void LocalPlayer::move(f32 dtime, Environment *env, f32 pos_max_d,
                camera_impact = getSpeed().Y * -1;
        }
 
-       {
-               camera_barely_in_ceiling = false;
-               v3s16 camera_np = floatToInt(getEyePosition(), BS);
-               MapNode n = map->getNode(camera_np);
-               if (n.getContent() != CONTENT_IGNORE) {
-                       if (nodemgr->get(n).walkable && nodemgr->get(n).solidness == 2)
-                               camera_barely_in_ceiling = true;
-               }
-       }
-
        /*
                Check properties of the node on which the player is standing
        */
@@ -730,8 +720,7 @@ v3f LocalPlayer::getSendSpeed()
 
 v3f LocalPlayer::getEyeOffset() const
 {
-       float eye_height = camera_barely_in_ceiling ? m_eye_height - 0.125f : m_eye_height;
-       return v3f(0.0f, BS * eye_height, 0.0f);
+       return v3f(0.0f, BS * m_eye_height, 0.0f);
 }
 
 ClientActiveObject *LocalPlayer::getParent() const
@@ -1071,16 +1060,6 @@ void LocalPlayer::old_move(f32 dtime, Environment *env, f32 pos_max_d,
                camera_impact = getSpeed().Y * -1.0f;
        }
 
-       {
-               camera_barely_in_ceiling = false;
-               v3s16 camera_np = floatToInt(getEyePosition(), BS);
-               MapNode n = map->getNode(camera_np);
-               if (n.getContent() != CONTENT_IGNORE) {
-                       if (nodemgr->get(n).walkable && nodemgr->get(n).solidness == 2)
-                               camera_barely_in_ceiling = true;
-               }
-       }
-
        /*
                Update the node last under the player
        */