packing.
This commit is contained in:
@@ -53,6 +53,11 @@
|
||||
(.putString "save-1" (pr-str (entities :state)))
|
||||
.flush))
|
||||
|
||||
(defn get-texture [path]
|
||||
(let [atlas-name (str/replace path #".png" "")
|
||||
atlas (texture-atlas "packed/pack.atlas")]
|
||||
(texture (texture-atlas! atlas :find-region atlas-name))))
|
||||
|
||||
(defn has-save? []
|
||||
(-> (.getPreferences (Gdx/app) "ticks-tales-saves")
|
||||
(.contains "save-1")))
|
||||
@@ -140,7 +145,7 @@
|
||||
|
||||
|
||||
(defn make-bird [screen p]
|
||||
(let [bird-sheet (texture! (texture "outside-castle/bird.png") :split 1 2)
|
||||
(let [bird-sheet (texture! (get-texture "outside-castle/bird.png") :split 1 2)
|
||||
bird-stand (animation 0.15 (for [i [0 1]]
|
||||
(aget bird-sheet 0 i)))]
|
||||
(assoc (animation->texture screen bird-stand)
|
||||
|
||||
Reference in New Issue
Block a user