OK, two more variations.
;; CAB 04.03.07
;; Enter rise and Left Or Right Slope
(defun c:slope (/ tmp run)
(or *rise (setq *rise 6.))
(and (setq tmp (getreal (strcat "\nSlope: ?/12 <" (rtos *rise 2 2) "> ")))(setq *rise tmp))
(and
(or (> 12.001 *rise 0) (prompt "\nOut of range!"))
(not (initget 0 "Right Left"))
(if (= "Right" (getkword "\nWhich slope? [Right/Left] < Left >: "))
(setq run -12.)
(setq run 12.)
)
(setvar "snapang" (angle '(0.0 0.0) (list run *rise)))
)
(print)
)
(defun c:sl0() ; reset to zero
(setvar "snapang" 0.0)
(princ)
)
This one enter "SLO 0" to reset the snap angle, use "SLO 4" for 4/12
;; CAB 04.03.07
;; Enter SLO then space then the Rise, use negative number for Right Slope
(defun c:slo (/ rise)
(and
(setq rise (getreal "\nEnter Slope Rise: ?/12 "))
(or (>= 12.00 rise -12) (prompt "\nOut of range! 0-12"))
(setvar "snapang" (angle '(0.0 0.0) (list 12. rise)))
)
(princ)
)