                 player)
         eff
             (Math/pow efficiency time-step)
+        ]
+    (step-thing player time-step eff)))
 
-        player
-            (assoc player
-                :x (mod (+ (:x player) (* (:xv player) time-step)) width)
-                :y (mod (+ (:y player) (* (:yv player) time-step)) height)
-                :a (mod (+ (:a player) (* (:av player) time-step)) (* Math/PI 2.0))
-                :xv (* (:xv player) eff)
-                :yv (* (:yv player) eff)
-                :av (* (:av player) eff))]
-
-        player))
-
+(defn asteroid-step [asteroid time-step]
+    (step-thing asteroid time-step 1.0))
 
 (defn game-step [state keys-pressed]
     (let [new-time (now) time-step (- new-time (:time state))]
         (assoc state
             :time new-time
-            :player (player-step (:player state) time-step keys-pressed))))
+            :player (player-step (:player state) time-step keys-pressed)
+            :asteroids (map (fn [a] (asteroid-step a time-step)) (:asteroids state))
+)))
 
 (defn create-game []
     (let [


(defn now [] (* 0.001 (System/currentTimeMillis)))

(defn default-state [] {
    :time (now)
    :player { :x 100.0 :y 100.0 :xv 0.0 :yv 0.0 :a 0.0 :av 0.0 } } )



(defn player-step [player time-step keys-pressed]
    (let [

            (.fill g (player-shape))
            (.setTransform g old-transform))))

(defn asteroid-shape [radii]
    ((fn [p r a ai]
        (if (empty? r)
            p
            (recur
                (doto p
                    (.addPoint
                        (* (Math/cos a) (first r))
                        (* (Math/sin a) (first r))))
                (rest r)
                (+ a ai)
                ai)))
        (new Polygon)
        radii
        0.0
        (/ (* Math/PI 2.0) (count radii))))

(defn draw-asteroid [asteroid g]
    (do
        (.setColor g (Color/GRAY))
        (let [old-transform (.getTransform g)]
            (.translate g (:x asteroid) (:y asteroid))
            (.rotate g (:a asteroid))
            (.fill g (asteroid-shape (:radii asteroid)))
            (.setTransform g old-transform))))

(defn game-render [state g]
    (do
        (.setRenderingHint g
