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

to the length of children

This commit is contained in:
Justin Lin
2017-06-17 18:08:06 +08:00
parent 56facf9e1c
commit 2681fbce0b

View File

@@ -30,9 +30,11 @@ module along_with(points, angles, twist = 0, scale = 1.0) {
(scale[1] - 1) / leng_points_minus_one,
scale[2] == undef ? 0 : (scale[2] - 1) / leng_points_minus_one
] : scale_step();
end_i = $children == 1 ? leng_points_minus_one : $children - 1;
function _path_angles(pts, i = 0) =
i == leng_points_minus_one ?
i == end_i ?
[] :
concat(
[__angy_angz(pts[i], pts[i + 1])],