 
 (def app-state (atom {:text "Hello Chestnut!"
                       :hero {:move false
+                             :dx 0
+                             :dy 0
                              :life 100
                              :position (hero-start-position grid-content)
                              :jump {:time nil :bottom nil}

        (om/update! app [:game-over] true)
        (go-loop []

          (let [new-hero (-> (get-in @app [:hero])
                              move-horizontally

                              move-vertically
                              ;;(partial update-hero app)
                              )]
            ;;(console-log (new-hero :position))
            ;;(console-log (new-hero :jump))
            (om/update! app [:hero] new-hero)
            )


(defn stop-moving [e app]
  (condp = (aget e "keyCode")
    88 (om/update! app [:hero :dx] 0)
    90 (om/update! app [:hero :dx] 0)
    nil
    )
  )
