mazzetti68
Guest
Hello, everyone!
I would like to create in lsp, a function that when creating a data line two points:
create this line on a new layer. (color 2, called "line")
and create another one when I make a circle: (color 10, called "circle")
(Make the two codes are attached)
later everything is grouped (autocad group, instead of block).
Thank you in advance and... good afternoon to all! !
I would like to create in lsp, a function that when creating a data line two points:
Code:
(setq p1 (getpoint "\nindicates the starting point of the panel line: ")
(setq p2 (getpoint "\nindicates the end point of the panel line: ")
(setq p1x (nth 0 p1))
(setq p1y (nth 1 p1))
(setq p1z (nth 2 p1))
(setq p1+6 (list(+ p1x 0.06) p1y p1z))
(setq p2x (nth 0 p2))
(setq p2y (nth 1 p2))
(setq p2z (nth 2 p2))
(setq p2-6 (list p2x p1y p1z))
(command "_line" p1+6 "_non" p2-6 ")
and create another one when I make a circle: (color 10, called "circle")
Code:
(setq c1 (getpoint "\nindicates the point of the center of the circle: ")
(setq c2 (getpoint "\nindicates the radius amplitude point: ")
(command "_circle" c1 c2)
later everything is grouped (autocad group, instead of block).
Thank you in advance and... good afternoon to all! !
