From b8ab409fc09f19e2fa266f1949f4d90d307aae15 Mon Sep 17 00:00:00 2001 From: Glen Whitney Date: Sun, 26 Nov 2023 20:18:20 -0800 Subject: [PATCH] feat: add line-foot construction method --- src/adapptlet.civet | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/adapptlet.civet b/src/adapptlet.civet index 37b29ef..1497df8 100644 --- a/src/adapptlet.civet +++ b/src/adapptlet.civet @@ -728,6 +728,17 @@ classHandler: Record := commands.push `${aux} = Translate(${source}, ${displacement})` auxiliaries.push aux ends[1] = aux + 'foot' + pt := args.subpoints + unless pt then return + destination := args.plane + ? args.plane[0] + : `Line(${pt[1]},${pt[2]})` + ends[0] = pt[0] + commands.push + `${aux} = ClosestPoint(${destination}, ${pt[0]})` + auxiliaries.push aux + ends[1] = aux 'parallel' unless args.subpoints then return [newStart, oldStart, oldEnd] := args.subpoints -- 2.34.1