hehoubin
发表于 2012-10-1 21:08:05
能写个全的吗
hehoubin
发表于 2012-10-1 21:14:35
Y轴第二点Y轴的正数方向,X轴的90度角
x轴第二点x轴的负数数方向,y轴的90度角
hehoubin
发表于 2012-10-1 21:22:36
老师这样能写吗
Andyhon
发表于 2012-10-1 21:40:30
看来您得琢磨琢磨 Mirror 命令
弄通了才知命令列需要什么样的回应值
(程序也是接手人的回应而已)
hehoubin
发表于 2012-10-1 22:03:17
例如这个Y轴镜像不是平行Y 轴的正数方向的另一个点就可以可以镜像吗
hehoubin
发表于 2012-10-1 22:08:54
我发个附件您
hehoubin
发表于 2012-10-1 22:48:09
attach://70778.rar
hehoubin
发表于 2012-10-1 22:58:19
hehoubin
发表于 2012-10-1 23:02:57
老师按文件的那样可以写了吗
Andyhon
发表于 2012-10-2 08:55:00
镜像处理只部份理解 ...
(defun jk1 (msg blk)
(princ msg)
(setq ss (ssget)
pt (getpoint "\nBase point: ")
)
(command "_block" blk "non" pt ss "")
(command "_insert" blk "non" pt "" "" "")
)
(defun jk2(msg blk)
(princ msg)
(setq ss (ssget)
pt (getpoint "\nBase point: ")
)
(command "_block" blk "y" "non" pt ss "")
(command "_insert" blk "non" pt "" "" "")
)
(defun c:c1 ();/ pt ss)
(if (tblsearch "block" "C1")
(progn
(initget 1 "C")
;; 提示((C)重新建C1块)的可选项
(setq pt (getpoint "\nInsert point or (C)重新建C1块: "))
(cond
((= pt "C") (jk2 "重新建C1块: " "C1"))
(T
;; 添加一个将 (“C1块”镜像后插入)的可选项
(initget "No Yes")
(setq ans (GetKword "\n “C1块”要镜像吗?: <No> / Yes: "))
(command "_insert" "C1" "non" pt "" "" "")
;; Mirror
(cond
((= ans "Yes")
;; 此处仍得探讨
(command "Mirror" (entlast) "" "non" pt)
(while (= (logand (getvar "CmdActive") 1) 1) (command pause))
)))))
(jk1 "\n请选择创建块C1的图元: " "C1")
)
(princ)
)