inside castle.
This commit is contained in:
@@ -29,7 +29,9 @@
|
||||
(fn [state] (assoc state :safe-listen-count (inc (:safe-listen-count state 0))))))
|
||||
|
||||
(defn make [screen]
|
||||
(let [[screet atlas] (utils/acquire-atlas screen "packed/behindhouse.atlas")]
|
||||
(let [[screet atlas] (utils/acquire-atlas screen "packed/behindhouse.atlas")
|
||||
[screet global-atlas] (utils/acquire-atlas screen "packed/global.atlas")]
|
||||
|
||||
(rooms/make :music {:day :town-2 :night :night}
|
||||
:name "Behind house"
|
||||
:interactions
|
||||
@@ -157,7 +159,7 @@
|
||||
(actions/do-dialogue entities
|
||||
:ego "I should be careful with this sword."
|
||||
:ego "It's sharp!"))})
|
||||
:bird (utils/make-bird screen [[50 235] [80 220] [100 239] [180 235] [85 225]])
|
||||
:bird (utils/make-bird screen global-atlas [[50 235] [80 220] [100 239] [180 235] [85 225]])
|
||||
:outside-particles (common/make-outside-particles)}
|
||||
:collision "behindhouse/collision.png"
|
||||
:scale-fn (utils/scaler-fn-with-baseline 110 0.10 1.00)
|
||||
|
||||
@@ -521,14 +521,14 @@
|
||||
(particle-effect! magic :allow-completion)
|
||||
entities)
|
||||
entities))}]
|
||||
:entities {:bird-1 (utils/make-bird screen (as-> [[185 235]
|
||||
:entities {:bird-1 (utils/make-bird screen global-atlas (as-> [[185 235]
|
||||
[220 225] [210 230] [250 235]] p
|
||||
(concat p (reverse p))))
|
||||
:sign (assoc (animation->texture screen sign )
|
||||
:anim sign
|
||||
:anim-start 0
|
||||
:x 125 :y 138 :baseline 239)
|
||||
:bird-2 (utils/make-bird screen (as-> [[220 225] [195 235] [210 230] [250 225]] p
|
||||
:bird-2 (utils/make-bird screen global-atlas (as-> [[220 225] [195 235] [210 230] [250 225]] p
|
||||
(concat p (reverse p))))
|
||||
|
||||
:outside-particles (common/make-outside-particles)
|
||||
|
||||
@@ -328,6 +328,7 @@
|
||||
|
||||
(defn make [screen]
|
||||
(let [[screen atlas] (utils/acquire-atlas screen "packed/outside-castle.atlas")
|
||||
[screen global-atlas] (utils/acquire-atlas screen "packed/global.atlas")
|
||||
peddler-sheet (texture! (utils/atlas->texture atlas "peddler-talk" ) :split 18 36)
|
||||
peddler-talk (animation 0.18 (for [i (flatten [2 3 2 3 2 3 6 1 0 1 0 1 0 1 0 1 2 3 2 3 2 3 6 4 5 4 5 4 5 4 5])]
|
||||
(aget peddler-sheet 0 i)))
|
||||
@@ -473,7 +474,7 @@
|
||||
:script (actions/get-script entities
|
||||
(actions/talk entities :ego "Those look like the choicest of balloons.")))
|
||||
:stand)
|
||||
:bird (utils/make-bird screen (as-> [[82 235] [134 215] [185 235] [165 238]
|
||||
:bird (utils/make-bird screen global-atlas (as-> [[82 235] [134 215] [185 235] [165 238]
|
||||
[220 225] [210 230] [250 235]] p
|
||||
(concat p (reverse p))))
|
||||
|
||||
|
||||
@@ -393,8 +393,8 @@
|
||||
(animation speed (split-texture atlas file [w h] frames))))
|
||||
|
||||
|
||||
(defn make-bird [screen p]
|
||||
(let [bird-sheet (texture! (get-texture "outside-castle/bird.png") :split 1 2)
|
||||
(defn make-bird [screen global-atlas p]
|
||||
(let [bird-sheet (texture! (atlas->texture global-atlas "bird") :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