diff options
author | est31 <MTest31@outlook.com> | 2016-01-25 00:06:01 +0100 |
---|---|---|
committer | est31 <MTest31@outlook.com> | 2016-01-29 15:53:54 +0100 |
commit | 4e93ba06a749fa2503786bf8d7dbda3d1e36a65a (patch) | |
tree | a694b86c85ab9b14e59ae060ea51eba6c44c8ce9 /src/localplayer.cpp | |
parent | ad884f23d4e73d38ce0f529de49591dd66cee44d (diff) | |
download | minetest-4e93ba06a749fa2503786bf8d7dbda3d1e36a65a.tar.gz minetest-4e93ba06a749fa2503786bf8d7dbda3d1e36a65a.tar.bz2 minetest-4e93ba06a749fa2503786bf8d7dbda3d1e36a65a.zip |
Don't pass non-const references to collision methods
Non const references cause a lot of confusion with behaviour of code,
and are disallowed by minetest style guide.
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r-- | src/localplayer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp index fd781f940..60aec95d4 100644 --- a/src/localplayer.cpp +++ b/src/localplayer.cpp @@ -214,8 +214,8 @@ void LocalPlayer::move(f32 dtime, Environment *env, f32 pos_max_d, v3f accel_f = v3f(0,0,0); collisionMoveResult result = collisionMoveSimple(env, m_gamedef, - pos_max_d, m_collisionbox, player_stepheight, dtime, - position, m_speed, accel_f); + pos_max_d, m_collisionbox, player_stepheight, dtime, + &position, &m_speed, accel_f); /* If the player's feet touch the topside of any node, this is |