diff options
author | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2011-08-10 08:07:30 +0200 |
---|---|---|
committer | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2011-08-11 15:22:35 +0200 |
commit | c007d8219e0ed138e0cebd1492efac7a33ee2068 (patch) | |
tree | ff9a90f0af2da446eb15e2bc1f3684c779bc1d4e /src | |
parent | b318e82356c185b54ef4cd404704422ea24fa277 (diff) | |
download | minetest-c007d8219e0ed138e0cebd1492efac7a33ee2068.tar.gz minetest-c007d8219e0ed138e0cebd1492efac7a33ee2068.tar.bz2 minetest-c007d8219e0ed138e0cebd1492efac7a33ee2068.zip |
Server should use the same eye position as the client
Diffstat (limited to 'src')
-rw-r--r-- | src/server.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/server.cpp b/src/server.cpp index 8a19306a9..c2fb6097e 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -380,8 +380,7 @@ void RemoteClient::GetNextBlocks(Server *server, float dtime, v3s16 center = getNodeBlockPos(center_nodepos); // Camera position and direction - v3f camera_pos = - playerpos + v3f(0, BS+BS/2, 0); + v3f camera_pos = player->getEyePosition(); v3f camera_dir = v3f(0,0,1); camera_dir.rotateYZBy(player->getPitch()); camera_dir.rotateXZBy(player->getYaw()); |