1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-21 22:05:27 +02:00

remove angle

This commit is contained in:
Justin Lin
2020-05-09 12:21:17 +08:00
parent c2fe6ca4f9
commit 701d13bcce

View File

@@ -40,17 +40,15 @@ poly = footprints2(
["turn", 90], ["turn", 90],
["forward", 10] ["forward", 10]
] ]
), )
start = [10, 10],
angle = 90
); );
hull_polyline2d(poly, width = 1); hull_polyline2d(poly, width = 1);
``` ```
*/ */
function footprints2(cmds, start = [0, 0], angle = 0) = function footprints2(cmds, start = [0, 0]) =
let( let(
t = turtle2d("create", start[0], start[1], angle), t = turtle2d("create", start[0], start[1], 0),
leng = len(cmds) leng = len(cmds)
) )
concat([turtle2d("pt", t)], _footprints2(cmds, t, leng)); concat([turtle2d("pt", t)], _footprints2(cmds, t, leng));