1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-17 20:11:50 +02:00

change end cond

This commit is contained in:
Justin Lin
2019-06-23 08:53:32 +08:00
parent c0fb254c43
commit 4aff538837

View File

@@ -1,7 +1,7 @@
function __lines_from(pts, closed = false) = function __lines_from(pts, closed = false) =
let(leng = len(pts)) let(leng = len(pts))
concat( concat(
[for(i = 0; i < leng - 1; i = i + 1) [pts[i], pts[i + 1]]], [for(i = 0; i <= leng; i = i + 1) [pts[i], pts[i + 1]]],
closed ? [[pts[len(pts) - 1], pts[0]]] : [] closed ? [[pts[len(pts) - 1], pts[0]]] : []
); );