上边程序并不能完全转换正确,郁闷。
上个图看看 ;;;土法炼钢的方法
(defun c:test_1-1()
(command "ucs" "w")
(command "ucs" "z" "-90")
(command "ucs" "y" "-90")
(setq qq (trans (cdr (assoc 10 (entget (car (entsel))))) 0 1))
(princ qq)
(command "ucs" "w")
(command "id")
)
非常感谢masterlong
依据masterlong提供方法测试 o.k.
(defun c:test_1-2()
(setq block-ent (car (entsel)))
(setq qq (trans (cdr (assoc 10 (entget block-ent))) block-ent 1))
(princ qq)
(command "ucs" "w")
(command "id")
)
有个困惑可否麻烦masterlong解答
(trans (cdr (assoc 10 (entget block-ent))) block-ent 1)的用法
一般常看到
(trans (cdr (assoc 10 (entget block-ent))) 0 1)
或
(trans (cdr (assoc 10 (entget block-ent))) 1 0)
第一次看到这种用法
block-ent 1的方式
页:
1
[2]