From 7d5e2c3a1d8a8f9b0fbcd6ecf3803467cab4eb16 Mon Sep 17 00:00:00 2001 From: Kevin Boulain Date: Sat, 18 May 2019 23:46:26 +0200 Subject: [PATCH] Fix right_triangle ORIENT_Z --- shapes.scad | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/shapes.scad b/shapes.scad index 76d3a4c9..a3d53ec3 100644 --- a/shapes.scad +++ b/shapes.scad @@ -360,11 +360,11 @@ module right_triangle(size=[1, 1, 1], orient=ORIENT_Y, anchor=ALLNEG, center=und } } else if (orient == ORIENT_Z) { ang = atan2(size.x, size.y); - masksize = [norm([size.x,size.y]), size.y, size.z] + [1,1,1]; - zrot(-ang) { + masksize = [size.y, norm([size.x,size.y]), size.z] + [1,1,1]; + zrot(ang) { difference() { - zrot(ang) cube(size, center=true); - back(masksize.y/2) cube(masksize, center=true); + zrot(-ang) cube(size, center=true); + right(masksize.x/2) cube(masksize, center=true); } } }