1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-02-11 19:04:32 +01:00
This commit is contained in:
Justin Lin 2020-05-09 16:18:58 +08:00
parent 5d88685e78
commit b16d0158d9
3 changed files with 6 additions and 4 deletions

View File

@ -26,8 +26,8 @@ function _next_t2(t, code, angle, leng) =
code == "|" ? turtle3d("zu_turn", t, 180) :
code == "&" ? turtle3d("yu_turn", t, angle) :
code == "^" ? turtle3d("yu_turn", t, -angle) :
code == "\\" ? turtle3d("xu_turn", t, angle) :
code == "/" ? turtle3d("xu_turn", t, -angle) : t;
code == "\\" ? turtle3d("xu_turn", t, -angle) :
code == "/" ? turtle3d("xu_turn", t, angle) : t;
// It doesn't use recursion to avoid recursion error.
function _lines(t, codes, angle, leng) =

View File

@ -121,7 +121,8 @@ function _turtle3d_chain_move(cmd, arg1, arg2) =
cmd == "zu_move" ? _turtle3d_zu_move(arg1, arg2) : _turtle3d_chain_turn(cmd, arg1, arg2);
function _turtle3d_chain_turn(cmd, arg1, arg2) =
cmd == "xu_turn" || cmd == "roll" ? _turtle3d_xu_turn(arg1, arg2) :
cmd == "xu_turn" ? _turtle3d_xu_turn(arg1, arg2) :
cmd == "roll" ? _turtle3d_xu_turn(arg1, -arg2) :
cmd == "yu_turn" ? _turtle3d_yu_turn(arg1, arg2) :
cmd == "pitch" ? _turtle3d_yu_turn(arg1, -arg2) :
cmd == "zu_turn" || cmd == "turn" ? _turtle3d_zu_turn(arg1, arg2) : _turtle3d_chain_one_arg(cmd, arg1);

View File

@ -23,7 +23,8 @@ function xy_arc_cmds(radius, angle, steps) =
],
[["forward", leng], ["turn", ta]]
);
// cmds: "forward" ("xu_move"), "turn" ("zu_turn"), "roll" ("xu_turn"), "pitch" (negative "yu_turn")
poly = footprints3(
concat(
[