Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 08/17/2024 in Posts

  1. Try this, note you need to do the is it a block "INSERT" or a "LWPOLYLINE" choice. (defun c:wow ( / oldsnap d1 d2 plent) (setq oldsnap (getvar 'osmode)) (setvar 'osmode 1) (while (setq pt (getpoint "\nPick control corner Enter to exit ")) (setq ss (ssget pt)) (setq plent (ssname ss 0)) (setq lay (cdr (assoc 8 (entget plent)))) (setq co-ord (mapcar 'cdr (vl-remove-if-not '(lambda (x) (= (car x) 10)) (entget plent)))) (setq d1 (distance (car co-ord) (cadr co-ord))) (setq d2 (distance (cadr co-ord) (caddr co-ord))) (if (< d2 d1) (command "rectang" "D" d1 d2 pt (getvar 'extmax)) (command "rectang" "D" d2 d1 pt (getvar 'extmax)) ) (command "erase" plent "") ) (setvar 'osmode oldsnap) (princ) ) (c:wow)
    1 point
×
×
  • Create New...