zhgcr旋转复制实体
;;;旋转复制实体(以角度)(defun c:copyrt(/ ss r p1 osm jd s)
(setvar "cmdecho" 0)
(setq jd (getvar "auprec"))
(setvar "auprec" 5)
(setq osm (getvar "osmode"))
(princ "\n ***** 旋转复制实体程序 ***** ")
(princ "\n 请选择旋转复制的实体:")
(setq ss (ssget))
(if (= ss nil)(progn (princ "\n 请选择旋转复制的实体:")(setq ss (ssget))))
(if (= ss nil)(progn (alert "\n您未选择有效的复制实体!请选择!")(setq ss (ssget))))
(setq p1 (getpoint "\n 请选择圆心点:"))
(if (= p1 nil)(setq p1 (getpoint "\n 请选择圆心点:")))
(command ".copy" ss "" p1 p1)
(command ".rotate" ss "" p1 "r" "0" pause)
(princ "\n 旋转复制完成!")
(command ".redraw")
(setvar "osmode" osm)
(setvar "auprec" jd)
(princ)
)
页:
[1]