door is much better.
This commit is contained in:
@@ -324,6 +324,7 @@
|
||||
lamb-walk-sheet (texture! (texture "outsidehouse/lamb-walk.png") :split 27 28)
|
||||
sheep-stand (animation 0.15 (for [i (flatten [(repeat 10 0) 1 2 3 4 5 6 7 4 5 6 7 8 9 10 (repeat 25 11) (repeat 15 12)])]
|
||||
(aget sheep-stand-sheet 0 i)))
|
||||
door (utils/make-anim "outsidehouse/door.png" [22 58] 0.15 (flatten [(range 4) 3 3 3 3 3 3 3]))
|
||||
sheep-walk (animation 0.05 (for [i (range 6)]
|
||||
(aget sheep-walk-sheet 0 i)))
|
||||
butterfly-stand (utils/make-anim "butterfly.png" [7 7] 0.1 [0 1])
|
||||
@@ -341,11 +342,11 @@
|
||||
entities
|
||||
(actions/walk-to entities :ego [257 90] :face :right)
|
||||
(actions/talk entities :ego (str "Anyone home?"))
|
||||
(sound! (sound "door.ogg") :play (utils/current-sound-volume))
|
||||
(actions/play-animation entities :ego :reach)
|
||||
(if (= :night (get-in @entities [:state :time]))
|
||||
(actions/talk entities :ego "It's locked.")
|
||||
(do (actions/transition-background entities :inside-house [237 0] :between (fn [s e]
|
||||
(do (actions/play-animation entities :door :open)
|
||||
(actions/transition-background entities :inside-house [237 0] :between (fn [s e]
|
||||
(if (= 1 (rand-int 10))
|
||||
(assoc-in e [:room :entities :experiment] (get-in e [:room :experiment]))
|
||||
e)))
|
||||
@@ -457,6 +458,12 @@
|
||||
:x 153
|
||||
:y 105
|
||||
:baseline 238)
|
||||
:door (assoc (animation->texture screen door)
|
||||
:x 253 :y 88 :baseline 122
|
||||
:open door
|
||||
:door-sound (sound "door.ogg")
|
||||
:anim-sound-frames {door {1 [:door-sound 1.0]}}
|
||||
)
|
||||
:lamb (assoc (texture "outsidehouse/lamb.png")
|
||||
:x 10 :y 163 :baseline 77
|
||||
:right {:stand (animation 0.1 [lamb-stand])
|
||||
|
||||
Reference in New Issue
Block a user