 
 (defn create [game]
   (set! (.-backgroundColor (.-stage game)) "#ffffff")
-  (.tileSprite (.-add game) 0 0 605 605 "border")
+  (.tileSprite (.-add game) 0 0
+               *phaser-border-width*
+               *phaser-border-height* "border")
   (create-possible-grids "possible-grid" game)
   (create-all-pieces "white-piece" "black-piece" game)
   (create-text game)

    (set! (.-restartButton game) restart-button)))

(def ^:dynamic *assets-table*
   ;name    path
  [["border"         "assets/reversi-border.png"]
   ["white-piece"    "assets/white-piece.png"]
   ["black-piece"    "assets/black-piece.png"]


(defn ^export start [game]
  (init-phaser game)
  (.add (.-state game) "main"
        (clj->js {:preload preload
                  :create create
                  }))
  (.start (.-state game) "main"))

(defprotocol Functor
  (restart [this]))
