大家好,最近开始学习macro编程,但是手头没有相关的参考书,就照着help做一些test,下面是自己写的一个小
程序,创建一个箱体,然后通过bool运算给它一个开口以出射光。但是选择文件,并在command键入
M :Aik& (creat_outbox 1550 2500 750 1450 2400) ,点击执行时出现
';z5]O~ *** ERROR *** edit:move: application of non-procedure: #[entity 1 3] "gPAxt 的错误。而且从tracepro的窗口看,箱体是建立起来了,但是没有移动
op%?V: (define creat_outbox
]XH}G9X^ (lambda (x_width y_length z_height x_out y_out)
wzRIvm{ (define outbox (insert:block x_width y_length z_height))
?w[M{ (edit:move (outbox) 0 0 130 ) ;help 中语法形式 BsX#
~
(define outputface (insert:block x_out y_out 10))
C8 b%r|^# (edit:move (outputface) 0 0 505) ;help 中语法形式 =_L
(define
`1[GY){?) outter (bool:subtract outbox outputface))
{PCf'n ))
'Na/AcRdg ;(creat_outbox 1550 2500 750 1450 2400)
!B3lsXLSY FiQx5}MMhu 如果我按照example中“Toroidal_Mirror.scm”的edit:move语句写程序(如下)就可以正确运行,
mxRe2<W (define creat_outbox
-^JGa{9* (lambda (x_width y_length z_height x_out y_out)
:a4FO (define outbox (insert:block x_width y_length z_height))
6v9{$: (define outbox (edit:move outbox 0 0 130)) Uieg4I ro
(define outputface (insert:block x_out y_out 10))
}bs2Rxkh (define outputface (edit:move outputface 0 0 505)) 6GD Uo}.
(define
7BX%z$_)A outter (bool:subtract outbox outputface))
2F[;Z*& ))
",ic"
~ FDAREE\j 想请教下其中错误的原因 _z!0ab LEJ7. 82 help中edit:move的
实例为
j{nkus2 B`4[@$ A_t<SG5
Z6b3gV C%P"Ds=w0N e;=G|E Hc@Z7eQ3^