 ; Wir - wire terminal blocks.
 ; Copyright 2001 by Rocket Software
 ; Why can't you get a couch upholstered in transparent vinyl?
 (DEFUN C:WIR (/ pasav pa orth pb dist angg num pb pc)
  (setvar "cmdecho" 0)
  (setq pasav (setq pa (getpoint "Start point: ")))
  (setq orth (getvar "orthomode"))
  (setvar "orthomode" 1)
  (setq pb (getpoint pa "\nPosition: "))
  (setvar "orthomode" orth)
  (setq dist (distance pa pb))
  (setq angg (angle pa pb))
  (setq num (getint "\nNumber of terminals: "))
  (repeat num (setq pb (polar pa angg (- dist 2.5)))
              (command ".line" pa pb "")
              (setq pc (polar pb angg 2.5))
              (setq pc (polar pc (* pi 1.5) 2.5))
              (command ".arc" "" pc)
              (setq pa (polar pa (* pi 1.5) 5)))
  (command ".line" (polar (polar pasav angg dist) (* pi 1.5) 2.5)
                   (polar (polar pa angg dist) (* pi 1.5) 5) "")
 (princ))