;1990/01/22 PM:
 (defun c:rupc ()
;(IF (= (TYPE F1) 'FILE ) "YES"  (STOP))
;(IF (= (TYPE F2) 'FILE ) "YES" (STOP))

 (defun setup()
   (setq ch (getstring "\n,D(4)(5)(6)(8)(10)(12) ?"))

   (setq l (getreal "\n How about the RUPC longer ?"))

   (setq base (getpoint "\n Where will you put on the RUPC ?"))
   (setq x1 (eval (car base)))
   (setq y1 (eval (cadr base)))

   (setvar "cmdecho" 1)
   (while (or (eq ch "4") (eq ch "D4")) (D4))
   (while (or (eq ch "5") (eq ch "D5")) (D5))
   (while (or (eq ch "6") (eq ch "D6")) (D6))
   (while (or (eq ch "8") (eq ch "D8")) (D8))
   (while (or (eq ch "10") (eq ch "D10")) (D10))
   (while (or (eq ch "12") (eq ch "D12")) (D12))
 )

 (defun D4()
   (setq d 8)
   (setq d0 4.0)
   (setq d2 2.8)
   (setq d3 2.3)
   (setq h 6.0)
   (setq h0 2.5)
   (setup1)
 )

 (defun D5()
   (setq d 9)
   (setq d0 5.0)
   (setq d2 3.3)
   (setq d3 2.8)
   (setq h 6)
   (setq h0 3)
   (setup1)
 )

 (defun D6()
   (setq d 10)
   (setq d0 6.0)
   (setq d2 3.8)
   (setq d3 3.0)
   (setq h 6)
   (setq h0 3)
   (setup1)
 )

 (defun D8()
   (setq d 13)
   (setq d0 8.0)
   (setq d2 4.8)
   (setq d3 4.0)
   (setq h 8)
   (setq h0 4)
   (setup1)
 )

 (defun D10()
   (setq d 15)
   (setq d0 10.0)
   (setq d2 5.8)
   (setq d3 4.8)
   (setq h 8)
   (setq h0 5)
   (setup1)
 )

 (defun D12()
   (setq d 17)
   (setq d0 12.0)
   (setq d2 7.2)
   (setq d3 6.2)
   (setq h 8)
   (setq h0 5)
   (setup1)
 )

 (defun setup1()
   (setq d/2 (/ d 2))
   (setq d0/2 (/ d0 2))
   (setq d2/2 (/ d2 2))
   (setq d3/2 (/ d3 2))
   (if (< l 0) (setq h (* -1 h)))
   (if (< l 0) (setq h0 (* -1 h0)))
   (setq l2 (+ l h0))
   (setq p1 (list (- x1 d/2) y1))
   (setq p2 (list (+ x1 d/2) y1))
   (setq p3 (list (+ x1 d/2) (+ y1 h)))
   (setq p4 (list (- x1 d/2) (+ y1 h)))
   (command "pline" p1 "w" "0" "0" p2 p3 p4 p1 "")

   (setq p5 (list (+ x1 d0/2) (+ y1 h)))
   (setq p6 (list (+ x1 d0/2) (+ y1 l)))
   (setq p7 (list (- x1 d0/2) (+ y1 l)))
   (setq p8 (list (- x1 d0/2) (+ y1 h)))
   (command "pline" p5 "w" "0" "0" p6 p7 p8 "")

   (setq p11 (list (+ x1 d3/2) (+ y1 l)))
   (setq p12 (list (+ x1 d2/2) (+ y1 l2)))
   (setq p13 (list (- x1 d2/2) (+ y1 l2)))
   (setq p14 (list (- x1 d3/2) (+ y1 l)))
   (command "pline" p11 "w" "0" "0" p12 p13 p14 "")
   (setup)
 )
   (setup)
 )
