beginning of explosion.
This commit is contained in:
BIN
desktop/resources/ego/swing-shovel.png
Normal file
BIN
desktop/resources/ego/swing-shovel.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 5.0 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
desktop/resources/ego/swingshovel.pxa/4.pxi
Normal file
BIN
desktop/resources/ego/swingshovel.pxa/4.pxi
Normal file
Binary file not shown.
BIN
desktop/resources/ego/swingshovel.pxa/5.pxi
Normal file
BIN
desktop/resources/ego/swingshovel.pxa/5.pxi
Normal file
Binary file not shown.
BIN
desktop/resources/ego/swingshovel.pxa/6.pxi
Normal file
BIN
desktop/resources/ego/swingshovel.pxa/6.pxi
Normal file
Binary file not shown.
BIN
desktop/resources/ego/swingshovel.pxa/7.pxi
Normal file
BIN
desktop/resources/ego/swingshovel.pxa/7.pxi
Normal file
Binary file not shown.
BIN
desktop/resources/ego/swingshovel.pxa/8.pxi
Normal file
BIN
desktop/resources/ego/swingshovel.pxa/8.pxi
Normal file
Binary file not shown.
@@ -18,5 +18,25 @@
|
||||
<key>duration</key>
|
||||
<real>1</real>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>duration</key>
|
||||
<real>1</real>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>duration</key>
|
||||
<real>1</real>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>duration</key>
|
||||
<real>1</real>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>duration</key>
|
||||
<real>1</real>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>duration</key>
|
||||
<real>1</real>
|
||||
</dict>
|
||||
</array>
|
||||
</plist>
|
||||
|
||||
@@ -225,7 +225,10 @@
|
||||
:sword (assoc (texture "dream/sword.png")
|
||||
:x 144 :y 122 :baseline 139
|
||||
:script (actions/get-script entities
|
||||
(read-sword-plaque entities)))
|
||||
(read-sword-plaque entities))
|
||||
:scripts {:shovel (actions/get-script entities
|
||||
(actions/walk-to entities :ego [148 76] :face :right)
|
||||
(actions/play-animation entities :ego :swing-shovel))})
|
||||
:broom (assoc (texture "dream/broom.png") :x 286 :y 122
|
||||
:path (catmull-rom-spline (map #(apply vector-2* %) [[286 122] [286 128]]) true)
|
||||
|
||||
|
||||
@@ -200,6 +200,7 @@
|
||||
glad (utils/make-anim "ego/glad.png" [20 46] 0.04 (flatten [0 1 2 3 4 (repeat 8 [5 5 5]) (repeat 20 0)]))
|
||||
milk (utils/make-anim "ego/squat.png" [18 36] 0.05 [0 1 2 2 3 3 3 3 3 3 6 5 6 5 6 5 6 5 6 5 6 5 6 5 6 5 6 5 6 5 3 3 3 3 3 3 3 3 3 3 3 2 1 0])
|
||||
throw (utils/make-anim "ego/throw.png" [18 36] 0.04 (flatten [[(repeat 5 0) (repeat 10 1)] (repeat 3 [2 2 2 3 3 3 4 4 4 5 5 5]) (repeat 5 [2 2 3 3 4 4 5 5]) (repeat 10 [2 3 4 5]) [2 3 3] (repeat 15 6)]))
|
||||
swing-shovel (utils/make-anim "ego/swing-shovel.png" [70 70] 0.1 (range 9))
|
||||
|
||||
ego {:right {:walk walk-right
|
||||
:stand stand-anim
|
||||
@@ -237,7 +238,9 @@
|
||||
:sigh sigh
|
||||
:glad glad
|
||||
:milk milk
|
||||
:throw throw}
|
||||
:throw throw
|
||||
:swing-shovel swing-shovel
|
||||
}
|
||||
:left {:walk (utils/flip walk-right)
|
||||
:stand (utils/flip stand-anim)
|
||||
:talk (utils/flip talk-anim)
|
||||
@@ -265,7 +268,8 @@
|
||||
:sigh (utils/flip sigh)
|
||||
:glad (utils/flip glad)
|
||||
:milk (utils/flip milk)
|
||||
:throw (utils/flip throw)}
|
||||
:throw (utils/flip throw)
|
||||
:swing-shovel (utils/flip swing-shovel)}
|
||||
:baseline (- 240 (last start-pos))
|
||||
:facing :right
|
||||
:origin-x 9
|
||||
@@ -324,6 +328,7 @@
|
||||
nil))
|
||||
:x (first start-pos) :y (last start-pos)
|
||||
:id "ego"}
|
||||
|
||||
ego (assoc ego :anim-sound-frames {(get-in ego [:left :walk]) {2 [:step-sound-1 1.0]
|
||||
6 [:step-sound-2 0.8]}
|
||||
(get-in ego [:right :walk]) {2 [:step-sound-1 1.0]
|
||||
@@ -350,6 +355,8 @@
|
||||
(get-in ego [:right :milk]) {8 [:milk-sound 1.0]}
|
||||
}
|
||||
:anim-merges {(get-in ego [:right :shock]) {:origin-x 15}
|
||||
(get-in ego [:left :swing-shovel]) {:origin-x 26}
|
||||
(get-in ego [:right :swing-shovel]) {:origin-x 26}
|
||||
:default {:origin-x 9}})]
|
||||
(actions/start-animation screen
|
||||
(merge (animation->texture screen (:stand (:right ego))) ego)
|
||||
@@ -395,7 +402,13 @@
|
||||
(merge entity (animation->texture (update-in screen [:total-time] #(- % (:anim-start entity)))
|
||||
(:anim entity))
|
||||
{:current-frame-index (texture! (:anim entity) :get-key-frame-index (get-animation-point (:anim entity) (- (:total-time screen) (:anim-start entity))))
|
||||
:previous-frame-index (texture! (:anim entity) :get-key-frame-index (get-animation-point (:anim entity) (- (:total-time screen) (:anim-start entity) (or (:delta-time screen) 0))))}
|
||||
:previous-frame-index (texture! (:anim entity) :get-key-frame-index (get-animation-point (:anim entity) (- (:total-time screen) (:anim-start entity) (or (:delta-time screen) 0))))
|
||||
:origin-x (or (get-in entity [:anim-origins (:anim entity) 0])
|
||||
(:base-origin-x entity)
|
||||
(:origin-x entity))
|
||||
:origin-y (or (get-in entity [:anim-origins (:anim entity) 1])
|
||||
(:base-origin-y entity)
|
||||
(:origin-y entity))}
|
||||
(or (get-in entity [:anim-merges (:anim entity)])
|
||||
(get-in entity [:anim-merges :default]))))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user