(defun c:tt()
(setq lst (list '(12752.4 7612.89 0.0) '(12744.4 7612.89 0.0) '(12744.4 7459.89 0.0) '(12752.4 7459.89 0.0) '(12752.4 7451.89 0.0) '(12744.4 7451.89 0.0) '(12744.4 7298.89 0.0) '(12752.4 7298.89 0.0)))
(foreach pt lst (getpoint pt))
)
(defun c:tt1()
(setq d (getreal"\n请输入填充比例(输入8,填充比例为1):"))
(setq lst (list
(list '(12752.4 7612.89 0.0) '(12744.4 7612.89 0.0) '(12744.4 7459.89 0.0) '(12752.4 7459.89 0.0))
(list '(12752.4 7451.89 0.0) '(12744.4 7451.89 0.0) '(12744.4 7298.89 0.0) '(12752.4 7298.89 0.0))
(list '(12769.4 7336.89 0.0) '(12769.4 7322.89 0.0) '(12824.4 7322.89 0.0) '(12824.4 7336.89 0.0))
(list '(12854.4 7336.89 0.0) '(12854.4 7322.89 0.0) '(12909.4 7322.89 0.0) '(12909.4 7336.89 0.0))
)
)
(foreach lst1 lst
(entmake (append (list '(0 . "HATCH") '(100 . "AcDbEntity") '(100 . "AcDbHatch") '(10 0.0 0.0 0.0) '(210 0.0 0.0 1.0) '(2 . "ANSI31") '(70 . 1) '(71 . 0) '(91 . 1) '(92 . 3) '(72 . 0) '(73 . 1) (cons 93 (length lst1))) (mapcar '(lambda (x) (cons 10 x)) lst1) (list '(97 . 0) '(75 . 0) '(76 . 1) '(98 . 0))))
(setq ent (entlast))
(entmod (subst (cons 41 (/ d 8.0)) (assoc 41 (entget ent)) (entget ent)))
(entmod (subst (cons 45 (* (cdr (assoc 45 (entget ent))) (/ d 8.0))) (assoc 45 (entget ent)) (entget ent)))
(entmod (subst (cons 46 (* (cdr (assoc 46 (entget ent))) (/ d 8.0))) (assoc 46 (entget ent)) (entget ent)))
)
)
;(foreach lst1 lst (entmake (append (list '(0 . "HATCH") '(100 . "AcDbEntity") '(67 . 0) '(410 . "Model") (cons 8 "0") '(100 . "AcDbHatch") '(10 0.0 0.0 0.0) '(210 0.0 0.0 1.0) '(2 . "ANSI31") '(70 . 1) '(71 . 0) '(91 . 1) '(92 . 3) '(72 . 0) '(73 . 1) (cons 93 (length lst1))) (mapcar '(lambda (x) (cons 10 x)) lst1) (list '(97 . 0) '(75 . 0) '(76 . 1) '(98 . 0)))))