马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?立即注册
×
Lee Mac 源贴http://www.lee-mac.com/nestedmove.html
简单写了几句,仅适用 0 角度等比同一块内子实体,没有模拟亮显
 - (defun c:tt (/ e lst p1 p2 mat v)
- (while (and (setq e (car (nentsel "\nPick Object In Insert: ")))
- (wcmatch (xdrx_getpropertyvalue
- (xdrx_getpropertyvalue e "Owner")
- "IsA"
- )
- "AcDbBlock*"
- )
- (setq lst (cons e lst))
- )
- )
- (and (and lst
- (setq p1 (getpoint "\nBase Point: "))
- (setq p2 (getpoint p1 "\nNext Point: "))
- (setq mat (xdrx_matrix_identity 3)
- v (mapcar '- p2 p1)
- )
- )
- (mapcar '(lambda (x)
- (xdrx_entity_transform
- x
- (xdrx_matrix_settranslation mat v)
- )
- )
- lst
- )
- (xdrx_object_regen)
- )
- (princ)
- )
|