diff options
author | kilbith <kilbith@users.noreply.github.com> | 2017-06-26 20:03:48 +0200 |
---|---|---|
committer | Loïc Blot <nerzhul@users.noreply.github.com> | 2017-06-26 20:03:48 +0200 |
commit | 1d1d922a7aafc464ec4483a2f8caa8c49ddbbdee (patch) | |
tree | 5d9b383e9efc02505327eb3798a9d93d1cd65dd2 /src/camera.h | |
parent | 936d67dad4c4939c9f7c30f489d8bfc74f47fcaf (diff) | |
download | minetest-1d1d922a7aafc464ec4483a2f8caa8c49ddbbdee.tar.gz minetest-1d1d922a7aafc464ec4483a2f8caa8c49ddbbdee.tar.bz2 minetest-1d1d922a7aafc464ec4483a2f8caa8c49ddbbdee.zip |
Add Arm Inertia (#6050)
Diffstat (limited to 'src/camera.h')
-rw-r--r-- | src/camera.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/camera.h b/src/camera.h index 8d213ede7..9ed4b7277 100644 --- a/src/camera.h +++ b/src/camera.h @@ -166,6 +166,8 @@ public: void drawNametags(); + inline void add_arm_inertia(f32 player_yaw, f32 frametime); + private: // Nodes scene::ISceneNode *m_playernode = nullptr; @@ -188,6 +190,12 @@ private: // Camera offset v3s16 m_camera_offset; + v2f m_wieldmesh_offset = v2f(55.0f, -35.0f); + v2f m_timer; + v2f m_cam_vel; + v2f m_cam_vel_old; + v2f m_last_cam_pos; + // Field of view and aspect ratio stuff f32 m_aspect = 1.0f; f32 m_fov_x = 1.0f; @@ -221,6 +229,7 @@ private: f32 m_cache_view_bobbing_amount; f32 m_cache_fov; f32 m_cache_zoom_fov; + bool m_arm_inertia; std::list<Nametag *> m_nametags; }; |