- (defun c:TY(/ en endata entype k n new_rad ss sub_upd_rad)
- (setq new_rad(getreal "请求输入圆的新半径值:"))
- (prompt "\n<<框选欲更新半径的圆>>")
- (setq ss(ssget))
- (setq n 0 k 0)
- (repeat(sslength ss)
- (setq en(ssname ss n))
- (setq endata(entget en))
- (setq entype (cdr(assoc 0 endata)))
- (if(= entype "CIRCLE")
- (progn
- (setq 40_list(assoc 40 endata))
- (setq new_40_list (cons 40 new_rad))
- (entmod(subst new_40_list 40_list endata))
- )
- )
- (setq n (1+ n))
- (setq k (1+ k))
- (prin1)
- )
- (princ(strcat "\n共有<" (itoa k) ">个圆更新半径=" (rtos new_rad)))
- (prin1)
- )
|