From 55f79f2e809f27e3e3d24e8f06cb86a9e28cffb0 Mon Sep 17 00:00:00 2001 From: Ivan Vodopiviz Date: Sat, 17 Mar 2018 23:32:07 +0100 Subject: [PATCH] Changed debug max distance to avoid overflow Changed it to roughly sqrt(FLT_MAX), it's a little less to account for float inaccuracies. Fixes #1835 --- servers/physics/collision_object_sw.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/servers/physics/collision_object_sw.h b/servers/physics/collision_object_sw.h index f5d32e56a01..dee28bb6dff 100644 --- a/servers/physics/collision_object_sw.h +++ b/servers/physics/collision_object_sw.h @@ -37,7 +37,8 @@ #include "shape_sw.h" #ifdef DEBUG_ENABLED -#define MAX_OBJECT_DISTANCE 10000000.0 +#define MAX_OBJECT_DISTANCE 3.1622776601683791e+18 + #define MAX_OBJECT_DISTANCE_X2 (MAX_OBJECT_DISTANCE * MAX_OBJECT_DISTANCE) #endif