From cbd3cf29af2e5157995720adbd850196fb5f69b1 Mon Sep 17 00:00:00 2001 From: Martin Budden Date: Wed, 16 Dec 2020 19:27:03 +0000 Subject: [PATCH] Fixed rounding error in hangin_hole assert. --- utils/hanging_hole.scad | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/hanging_hole.scad b/utils/hanging_hole.scad index ec1fb2a..564b9e8 100644 --- a/utils/hanging_hole.scad +++ b/utils/hanging_hole.scad @@ -35,7 +35,7 @@ module hanging_hole(z, ir, h = 100, h2 = 100) { //! Hole radius ```ir``` hanging poly_cylinder(r - eps, h - layer_height); } } - assert(z % layer_height == 0, str(z)); + assert(z - layer_height * floor(z / layer_height) < eps, str(z)); infill_angle = z % (2 * layer_height) ? -45 : 45; below = min(z + eps, h2); big = 1000;