mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-08-13 10:14:41 +02:00
fix end i
This commit is contained in:
@@ -1,7 +1,10 @@
|
|||||||
function __lines_from(pts, closed = false) =
|
function __lines_from(pts, closed = false) =
|
||||||
let(leng = len(pts))
|
let(
|
||||||
|
leng = len(pts),
|
||||||
|
endi = leng - 1
|
||||||
|
)
|
||||||
concat(
|
concat(
|
||||||
[for(i = 0; i <= leng; i = i + 1) [pts[i], pts[i + 1]]],
|
[for(i = 0; i < endi; i = i + 1) [pts[i], pts[i + 1]]],
|
||||||
closed ? [[pts[len(pts) - 1], pts[0]]] : []
|
closed ? [[pts[len(pts) - 1], pts[0]]] : []
|
||||||
);
|
);
|
||||||
|
|
Reference in New Issue
Block a user