From f6b019106730a767fafbef94b23b4d45f4777d57 Mon Sep 17 00:00:00 2001 From: Josh Wilson Date: Wed, 13 Aug 2008 22:23:30 +0000 Subject: [PATCH] returning at least 1 for grid size in getGridSizeFromSphere() --- direct/src/distributed/CartesianGridBase.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/direct/src/distributed/CartesianGridBase.py b/direct/src/distributed/CartesianGridBase.py index 0c549c3e71..ca16855b29 100755 --- a/direct/src/distributed/CartesianGridBase.py +++ b/direct/src/distributed/CartesianGridBase.py @@ -52,7 +52,7 @@ class CartesianGridBase: sphereRadius = Vec3(xMax,yMax,0).length() # sphereRadius = max(sphereRadius, gridRadius*cellWidth) - return 2 * (sphereRadius // cellWidth) + return max(2 * (sphereRadius // cellWidth), 1) def getZoneCellOrigin(self, zoneId): # It returns the origin of the zoneCell