(defun draw-rectangle (pnt width height rotation)
(setq pi (* 4.0 (atan 1.0)))
(setq angle (* rotation pi 180.0))
(setq x1 (car pnt))
(setq y1 (cadr pnt))
(setq x2 (+ x1 (* width (cos angle))))
(setq y2 (+ y1 (* width (sin angle))))
(setq x3 (+ x2 (* height (cos (+ angle (* pi 0.5))))))
(setq y3 (+ y2 (* height (sin (+ angle (* pi 0.5))))))
(setq x4 (+ x1 (* height (cos (+ angle (* pi 0.5))))))
(setq y4 (+ y1 (* height (sin (+ angle (* pi 0.5))))))
(command "line" pnt (list x2 y2))
(command "line" (list x2 y2) (list x3 y3))
(command "line" (list x3 y3) (list x4 y4))
(command "line" (list x4 y4) pnt)
)