summaryrefslogtreecommitdiff
path: root/src/player.h
diff options
context:
space:
mode:
authorKahrl <kahrl@gmx.net>2011-09-20 18:25:29 +0200
committerKahrl <kahrl@gmx.net>2011-09-20 18:25:29 +0200
commit6599002149f58c03b807cd1378ec17278dbdc09d (patch)
treed9f7ed6f77d8d42d40342ce1c30a1d02754745a5 /src/player.h
parentcbd2bcf102bd338ba1d97ad54bd257913f4dcd36 (diff)
downloadminetest-6599002149f58c03b807cd1378ec17278dbdc09d.tar.gz
minetest-6599002149f58c03b807cd1378ec17278dbdc09d.tar.bz2
minetest-6599002149f58c03b807cd1378ec17278dbdc09d.zip
fix a numerical problem, but tool is still jittery
Diffstat (limited to 'src/player.h')
-rw-r--r--src/player.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/player.h b/src/player.h
index ad0fb5ff9..350b85e1b 100644
--- a/src/player.h
+++ b/src/player.h
@@ -67,12 +67,17 @@ public:
return floatToInt(m_position + v3f(0,BS+BS/2,0), BS);
}
- v3f getEyePosition()
+ v3f getEyeOffset()
{
// This is at the height of the eyes of the current figure
- // return m_position + v3f(0, BS+BS/2, 0);
+ // return v3f(0, BS+BS/2, 0);
// This is more like in minecraft
- return m_position + v3f(0,BS+(5*BS)/8,0);
+ return v3f(0,BS+(5*BS)/8,0);
+ }
+
+ v3f getEyePosition()
+ {
+ return m_position + getEyeOffset();
}
virtual void setPosition(const v3f &position)