Founded by JohnWalker
CategoryCompany (defun C:SLOT ( )
(setvar "CMDECHO" 0) (setvar "BLIPMODE" 0) (setq oldsnap (getvar "OSMODE")) (setq diam (getdist "\nSlot Diameter : ") lngth (getdist "\nSlot Length : ")) (while (setq pt1 (getpoint "\nInsertion point:")) (setvar "OSMODE" 0) (setq pt2 (polar pt1 0.0 (/ (- lngth diam) 2.0)) pt3 (polar pt2 (/ pi 2.0) (/ diam 4.0)) pt4 (polar pt3 pi (- lngth diam)) pt5 (polar pt4 (* pi 1.5) (/ diam 2.0)) pt6 (polar pt5 0.0 (- lngth diam))) (command "PLINE" pt3 "W" (/ diam 2.0) "" pt4 "ARC" pt5 "LINE" pt6 "ARC" "CLOSE") (setvar "OSMODE" oldsnap) );while (princ)