aboutsummaryrefslogtreecommitdiff
path: root/src/client/localplayer.h
diff options
context:
space:
mode:
authorGaƫl C <gael-de-sailly@netc.eu>2018-12-01 10:01:32 +0100
committerSmallJoker <SmallJoker@users.noreply.github.com>2018-12-01 10:01:32 +0100
commit327bad2eafb8cfc05b7f831992be5700a167a53c (patch)
tree682d70aca114d7d350ed23b22075c96c2fc549be /src/client/localplayer.h
parentdcf58a3ad0c1092b3537039ee55892bb7dc83dee (diff)
downloadminetest-327bad2eafb8cfc05b7f831992be5700a167a53c.tar.xz
Added pitch fly mode (#7817)
In pitch fly mode, you fly to the exact direction you are pointing at, using the forward key. Other move directions are also pitched accordingly. It allows smoother and more complex movements. Can be enabled/disabled by L key by default (set keymap_pitchfly in minetest.conf)
Diffstat (limited to 'src/client/localplayer.h')
-rw-r--r--src/client/localplayer.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/localplayer.h b/src/client/localplayer.h
index 7148bc4de..28404aa01 100644
--- a/src/client/localplayer.h
+++ b/src/client/localplayer.h
@@ -149,8 +149,8 @@ public:
bool getAutojump() const { return m_autojump; }
private:
- void accelerateHorizontal(const v3f &target_speed, const f32 max_increase);
- void accelerateVertical(const v3f &target_speed, const f32 max_increase);
+ void accelerate(const v3f &target_speed, const f32 max_increase_H,
+ const f32 max_increase_V, const bool use_pitch);
bool updateSneakNode(Map *map, const v3f &position, const v3f &sneak_max);
float getSlipFactor(Environment *env, const v3f &speedH);
void handleAutojump(f32 dtime, Environment *env,