Multiple picks in Autocad
Multiple picks in Autocad
(OP)
Does anyone know how to write a macro for creating multiple pics? I often have to add dots to some 2d drawings to give them a more 3d effect. to do this I draw a small circle and copy it many many times. It wears me down after a few sheets. I wanted to know if htere was a way to hold down a key while moving the mouse around. Kind of like the spray feature in adobe photoshop.





RE: Multiple picks in Autocad
RE: Multiple picks in Autocad
then you can create a lisp routine to do the work you want done automatically.
RE: Multiple picks in Autocad
RE: Multiple picks in Autocad
Type Sketch
click once on the screen and just move the mouse.
When you done click the mouse to stop drawing.
.
.
But I'm not sure if that's the same effect you want as the dots. The sketch command is one long "sqiggly" polyline.
.
.
Just a thought.
Rich
RE: Multiple picks in Autocad
Try out this routine (asuming you are not using LT).
It draws points as you drag your cursor. Left click to stop drawing. If you want to draw a small circle, insert a block, etc you'll just need to change one line. Let me know how it works.
Carl
------------------------------------------------
(princ "Type SPRAY to start")
(defun c:spray ()
(setvar "cmdecho" 0)
(setq CurRead T TimeTol 0.0000002)
(setq OldTime (getvar "CDATE"))
(while CurRead
(setq ReadStuff (grread T 5 0)
NewTime (getvar "CDATE")
DeltaTime (- NewTime OldTime)
SprayFlag (if (> DeltaTime TimeTol) T nil)
);
(if (/= (car ReadStuff) 5) (setq CurRead nil))
(if SprayFlag
(progn
(setq Pt (cadr ReadStuff))
(entmake (list '(0 . "POINT") (cons 10 Pt)))
;;(command "point" Pt)
(setq OldTime NewTime)
);progn
);if
);while
(princ)
);defun
RE: Multiple picks in Autocad
RE: Multiple picks in Autocad
THAT'S IT !!!! just one thing. how would I change the points to circles with a radius of .0025?
Thanks so much. I've been trying for years to figure that out. :)
RE: Multiple picks in Autocad
You're welcome.
And to use circle with radius with of 0.0025, change the line
(entmake (list '(0 . "POINT") (cons 10 Pt)))
to
(entmake (list '(0 . "CIRCLE") (cons 10 Pt) (cons 40 0.0025)))
And to place objects faster or slower you can play with the value of "TimeTol 0.0000002",
for example 0.0000001 would place them twice as fast.
Carl
RE: Multiple picks in Autocad