I had modified only your attached "radialmove-new.lsp" for the Red highlighted things only...... (As the way your given code works)..... First you check this after that I shall move for other files.....
@jtm2020hyo wrote:
.................................
I need to update lisp to work with *lines, text, regular blocks or dynamic blocks. attached lisp-routines sometimes work others not.
Radial-move-copy-array.lsp routines should request to select objects to move/copy/array, then select 2 points to generate a circle, then request to select another point to generate another circle with the same center, then objects should be copy/move/array points from selected objects like SCALE COMMAND work. scale factor should be equivalent to our 2 circles creates.
for blocks or texts should be considered insert-point, for *lines their vertex, for closed objects like circles should be considered geometric-center.
By considering the "BoundingBox center" of each objects...... Try this....
(defun c:radialmove-new ( / ssx i ent p c d entplst)
(vl-load-com)
(setq c (getpoint "\nPick or specify center point for radial move : "))
(setq d (getdist "\nEnter distance to move: "))
(Princ "\nSelect Objects To Move Radially")
(setq ssx (ssget))
(setq i -1)
(while (setq ent (ssname ssx (setq i (1+ i))))
(vla-getBoundingBox (vlax-ename->vla-object ent) 'minpt 'maxpt)
(setq p
(mapcar '/
(mapcar '+ (vlax-safearray->list minpt) (vlax-safearray->list maxpt))
'(2 2 2)
)
)
(if p
(progn
(setq p (list (car p) (cadr p) (caddr p)))
(setq entplst (cons (cons p ent) entplst))
)
)
)
(foreach entp entplst
(if (equal c (car entp) 1E-13) ()
(command "_.move" (cdr entp) "" (car entp) (polar c (angle c (car entp)) (+ d (distance (car entp) c))))
)
)
(princ)
)
For the Blue highlighted things,... have to put different conditions into the code for different types of objects.......
Personally for me first show me your "Home Work" for the above conditions ......... then I surely help you.....
Tested in AutoCAD 2007.....
Debashis Bhunia
Co-Founder of Geometrifying Trigonometry(C)
________________________________________________
Walking is the First step of Running, Technique comes Next....