Actually, I found the routine interesting.
I just wanted to learn the first part, which was to do the curvature in real time.
Nothing more.
I really apologize for all the embarrassment.
I will leave here my last attempt because I was satisfied.
I'm sure there are more sophisticated ways, calculating and re-creating all objects, but I've lost even the will to learn by thinking that I might be hurting someone's intellectual property.
Probably I should have misinterpreted the purpose of a forum like this.
A good year for everyone.
(defun c:test (/ lastLine lastLine1 arc)
(vl-load-com)
(defun makeLine (pt1 pt2)
(redraw
(entmakex (list (cons 0 "LINE")
(cons 10 pt1)
(cons 11 pt2)
) ;_ >list
) ;_ >entmakex
1
) ;_ >redraw
(vlax-ename->vla-object (entlast))
) ;_ >defun
(setvar 'FILLETRAD 5) ;radius
(setq rad (getvar 'FILLETRAD))
(setq lastLine0 (makeLine
(setq pt1 (getpoint))
(setq pt1 (getpoint pt1))
) ;_ >makeLine
) ;_ >setq
(while (= (car (setq grr (grread t 0))) 5)
(if lastLine1
(if
(vl-catch-all-error-p
(setq err
(vl-catch-all-apply
'vla-delete
(list lastLine1)
) ;_ >vl-catch-all-apply
) ;_ >setq
) ;_ >vl-catch-all-error-p
(princ (strcat "\n** Error: "
(vl-catch-all-error-message err)
" **"
) ;_ >strcat
) ;_ >princ
(setq lastLine1 nil)
) ;_ >if
) ;_ >if
(if arc
(progn
(entdel arc)
(setq arc nil)
) ;_ >progn
) ;_ >if
(redraw)
(setq ep2 (cadr grr))
(if (> (distance pt1 ep2) rad)
(progn
(setq pt (polar ep2 (angle ep2 pt1) 1))
(setq lastLine1 (makeLine pt ep2))
(if
(vl-cmdf "_.fillet"
(vlax-curve-getPointAtDist lastLine0 0.5)
(vlax-curve-getPointAtDist lastLine1 0.5)
) ;_ >vl-cmdf
(redraw (setq arc (entlast)) 1)
(if lastLine1
(if
(vl-catch-all-error-p
(setq err
(vl-catch-all-apply
'vla-delete
(list lastLine1)
) ;_ >vl-catch-all-apply
) ;_ >setq
) ;_ >vl-catch-all-error-p
(princ (strcat "\n** Error: "
(vl-catch-all-error-message err)
" **"
) ;_ >strcat
) ;_ >princ
(setq lastLine1 nil)
) ;_ >if
) ;_ >if
) ;_ >if
) ;_ >progn
) ;_ >if
) ;_ >while
(princ)
) ;_ >defun