加载后运行时提示参数太少,请高手指导一下
(defun c:pdbhq (/p0 w l alf p1 p2 p3 p4 p5 p6 p7 p8 p9 d1 d2)(setq p0 (getpoint"\n输入保护区的定位点:"))
(setq w (getdist p0 "\n输入跑道加保护区的宽度:"))
(setq l (getdist"\n输入跑道的长度:"))
(setq d1 (getdist p0 "\n输入跑道宽度:"))
(setq d2 (getdist"\n输入保护区宽度:"))
(setq alf (getangle p0 "\n输入跑道的旋转角:"))
(setq p1 (polar p0(+ alf (* 0.5 pi)) d1))
(setq p2 (polar p0(+ alf (* -0.5 pi)) d1))
(setq p5 (polar p0(+ alf (* 0.5 pi))(+ d1 d2)))
(setq p6 (polar p0(+ alf (* -0.5 pi))(+ d1 d2)))
(setq p3 (polar p1 alf (-l)))
(setq p4 (polar p2 alf (-l)))
(setq p7 (polar p5 alf (-l)))
(setq p8 (polar p6 alf (-l)))
(setq p9 (polar p(+ alf pi) l))
(command "linetype""s""center" "");
(command "lweight" 0 );
(command "line" p0 p9"");
(command "linetype""s""bylayer" "");
(command "lweight" 0.6 );
(command "line"p5 p7 p8 p6 "c");
(command "lweight"0);
(command "line"p1 p3 "");
(command "line"p2 p4 "");
(command "lweight""bylayer")
)
(/p0 w l alf p1 p2 p3 p4 p5 p6 p7 p8 p9 d1 d2)→(/ p0 w l alf p1 p2 p3 p4 p5 p6 p7 p8 p9 d1 d2)
setq p3 (polar p1 alf (-l)))
(setq p4 (polar p2 alf (-l)))
(setq p7 (polar p5 alf (-l)))
(setq p8 (polar p6 alf (-l)))
(setq p9 (polar p(+ alf pi) l))
→
setq p3 (polar p1 alf (- l)))
(setq p4 (polar p2 alf (- l)))
(setq p7 (polar p5 alf (- l)))
(setq p8 (polar p6 alf (- l)))
(setq p9 (polar p0 (+ alf pi) l))
回复 xyp1964 的帖子
谢谢,已经可以运行了,非常感谢!
页:
[1]