From 5ae3d5d5490b2e53b98392a5859fc01b896b3572 Mon Sep 17 00:00:00 2001 From: Rock Storm Date: Thu, 4 Oct 2018 18:38:50 +0100 Subject: [PATCH] regular_shapes: rename reg_polygon Rename 'reg_polygon' to 'regular_polygon' to be consistent with the rest of OpenSCAD function names. --- regular_shapes.scad | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/regular_shapes.scad b/regular_shapes.scad index 54d61fd..5562850 100644 --- a/regular_shapes.scad +++ b/regular_shapes.scad @@ -27,7 +27,15 @@ module triangle(radius) polygon(points=[[-a,-o],[0,radius],[a,-o]],paths=[[0,1,2]]); } -module reg_polygon(sides,radius) +module reg_polygon(sides, radius) { + echo(" + DEPRECATED: function 'reg_polygon' is now deprecated + please use 'regular_polygon' instead"); + + regular_polygon(sides, radius); +} + +module regular_polygon(sides, radius) { function dia(r) = sqrt(pow(r*2,2)/2); //sqrt((r*2^2)/2) if only we had an exponention op if(sides<2) square([radius,0]);