aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSmallJoker <SmallJoker@users.noreply.github.com>2020-04-04 21:27:23 +0200
committerGitHub <noreply@github.com>2020-04-04 21:27:23 +0200
commitd5c441253669c9f88dea948d261e0d8934d28fb9 (patch)
tree4576053c6c867cc17caf5d3130d428ee3818fbf2 /src
parent86a0e991efff2fc616372f566a301352be28dae9 (diff)
downloadminetest-d5c441253669c9f88dea948d261e0d8934d28fb9.tar.gz
minetest-d5c441253669c9f88dea948d261e0d8934d28fb9.tar.bz2
minetest-d5c441253669c9f88dea948d261e0d8934d28fb9.zip
Revert collision tweaks #9365 and #9327 (#9591)
This reverts commit df74d369a395f0b99bd23fa3e7fb4c628c3df336. This reverts commit 908e76247922d4adf879b3996c4f75bdbb4e536d. Restores the original collision detection bugs to release 5.2.0 prior the large collision detection fix.
Diffstat (limited to 'src')
-rw-r--r--src/collision.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/collision.cpp b/src/collision.cpp
index a4c5454ae..a443be7ab 100644
--- a/src/collision.cpp
+++ b/src/collision.cpp
@@ -415,12 +415,12 @@ collisionMoveResult collisionMoveSimple(Environment *env, IGameDef *gamedef,
Collision uncertainty radius
Make it a bit larger than the maximum distance of movement
*/
- //f32 d = pos_max_d * 1.1f;
+ f32 d = pos_max_d * 1.1f;
+ // A fairly large value in here makes moving smoother
+ //f32 d = 0.15*BS;
-
- f32 d = 0.3f; // Temporary fix, any nonzero d causes collision glitches, the more the greater it is.
- // ultimately it has to be determined if any uncertainty is involved, and if it is, eliminated
- // and d & pos_max_d params removed from function calls.
+ // This should always apply, otherwise there are glitches
+ assert(d > pos_max_d); // invariant
int loopcount = 0;