mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 00:25:19 +02:00
Fix various clang-tidy reported performance-type-promotion-in-math-fn
This commit is contained in:
@@ -18,6 +18,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
*/
|
||||
|
||||
#include "collision.h"
|
||||
#include <cmath>
|
||||
#include "mapblock.h"
|
||||
#include "map.h"
|
||||
#include "nodedef.h"
|
||||
@@ -564,7 +565,7 @@ collisionMoveResult collisionMoveSimple(Environment *env, IGameDef *gamedef,
|
||||
box.MinEdge += *pos_f;
|
||||
box.MaxEdge += *pos_f;
|
||||
}
|
||||
if (fabs(cbox.MaxEdge.Y - box.MinEdge.Y) < 0.15f * BS) {
|
||||
if (std::fabs(cbox.MaxEdge.Y - box.MinEdge.Y) < 0.15f * BS) {
|
||||
result.touching_ground = true;
|
||||
|
||||
if (box_info.is_object)
|
||||
|
Reference in New Issue
Block a user