Improve spacing

This commit is contained in:
oakes
2014-05-25 14:30:37 -04:00
parent 2a7607463a
commit 63c316de64

View File

@@ -159,6 +159,7 @@ Now we can update our `:on-key-down` and `:on-touch-down` functions to move the
(move (first entities) :right) (move (first entities) :right)
(= (:key screen) (key-code :dpad-left)) (= (:key screen) (key-code :dpad-left))
(move (first entities) :left))) (move (first entities) :left)))
:on-touch-down :on-touch-down
(fn [screen entities] (fn [screen entities]
(let [pos (input->screen screen (:input-x screen) (:input-y screen))] (let [pos (input->screen screen (:input-x screen) (:input-y screen))]
@@ -321,6 +322,7 @@ You may want to display two different screens at once. This is useful in situati
(assoc (label "0" (color :white)) (assoc (label "0" (color :white))
:id :fps :id :fps
:x 5)) :x 5))
:on-render :on-render
(fn [screen entities] (fn [screen entities]
(->> (for [entity entities] (->> (for [entity entities]
@@ -328,6 +330,7 @@ You may want to display two different screens at once. This is useful in situati
:fps (doto entity (label! :set-text (str (game :fps)))) :fps (doto entity (label! :set-text (str (game :fps))))
entity)) entity))
(render! screen))) (render! screen)))
:on-resize :on-resize
(fn [screen entities] (fn [screen entities]
(height! screen 300))) (height! screen 300)))