cafeteria too.
|
Before Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 6.7 KiB |
|
Before Width: | Height: | Size: 3.1 KiB |
@@ -2,7 +2,7 @@
|
||||
(def packs (into ["do"]
|
||||
(mapcat (fn [directory]
|
||||
["run" "-m" "com.badlogic.gdx.tools.texturepacker.TexturePacker" (str "asset-work/" directory) "resources/packed/" (str directory ",")])
|
||||
["outside-jail"]
|
||||
["inside-cafeteria"]
|
||||
#_["behindhouse" "dream" "georgia" "inside-cafeteria" "inside-jail" "outsidehouse" "safe-song" "title"
|
||||
"castle-gate" "ego" "held" "inside-castle" "inside-stash" "outside-castle" "screenshots" "wizard"
|
||||
"cat-tree" "ending-castle" "inside-antique" "inside-house" "outside-jail" "space" ])))
|
||||
|
||||
@@ -1,250 +1,173 @@
|
||||
|
||||
inside-cafeteria.png
|
||||
size: 1024,1024
|
||||
format: RGBA8888
|
||||
format: RGBA4444
|
||||
filter: Nearest,Nearest
|
||||
repeat: none
|
||||
background
|
||||
rotate: false
|
||||
xy: 2, 594
|
||||
xy: 2, 778
|
||||
size: 320, 240
|
||||
orig: 320, 240
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
doorway
|
||||
rotate: false
|
||||
xy: 540, 262
|
||||
xy: 1000, 905
|
||||
size: 14, 113
|
||||
orig: 14, 113
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fg
|
||||
rotate: false
|
||||
xy: 2, 352
|
||||
xy: 324, 778
|
||||
size: 320, 240
|
||||
orig: 320, 240
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 2, 110
|
||||
size: 320, 240
|
||||
orig: 320, 240
|
||||
xy: 704, 584
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
index: 0
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 2, 497
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 1
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 260, 497
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 2
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 518, 390
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 3
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 2, 303
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 4
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 260, 303
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 5
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 518, 196
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 6
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 2, 109
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 7
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 260, 109
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 8
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 518, 2
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 9
|
||||
glow
|
||||
rotate: false
|
||||
xy: 324, 594
|
||||
xy: 646, 778
|
||||
size: 320, 240
|
||||
orig: 320, 240
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
hands-fight-1
|
||||
rotate: false
|
||||
xy: 2, 2
|
||||
size: 106, 106
|
||||
orig: 106, 106
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
hands-fight-2
|
||||
rotate: false
|
||||
xy: 324, 358
|
||||
size: 106, 106
|
||||
orig: 106, 106
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
hands-fight-3
|
||||
rotate: false
|
||||
xy: 110, 2
|
||||
size: 106, 106
|
||||
orig: 106, 106
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
hands-fight-4
|
||||
rotate: false
|
||||
xy: 324, 250
|
||||
size: 106, 106
|
||||
orig: 106, 106
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
hands-fight-5
|
||||
rotate: false
|
||||
xy: 432, 358
|
||||
size: 106, 106
|
||||
orig: 106, 106
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
hands-fight-6
|
||||
rotate: false
|
||||
xy: 324, 142
|
||||
size: 106, 106
|
||||
orig: 106, 106
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
hands-fight-7
|
||||
rotate: false
|
||||
xy: 432, 250
|
||||
size: 106, 106
|
||||
orig: 106, 106
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
knight-a
|
||||
rotate: false
|
||||
xy: 2, 918
|
||||
xy: 2, 691
|
||||
size: 700, 85
|
||||
orig: 700, 85
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
knights
|
||||
rotate: false
|
||||
xy: 218, 11
|
||||
xy: 518, 592
|
||||
size: 74, 97
|
||||
orig: 74, 97
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
knights-stand
|
||||
rotate: false
|
||||
xy: 2, 836
|
||||
xy: 2, 27
|
||||
size: 490, 80
|
||||
orig: 490, 80
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
ladder
|
||||
rotate: false
|
||||
xy: 494, 878
|
||||
xy: 968, 905
|
||||
size: 29, 38
|
||||
orig: 29, 38
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
ladder-guard
|
||||
rotate: false
|
||||
xy: 540, 377
|
||||
size: 74, 87
|
||||
orig: 74, 87
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
ladder-guard-2
|
||||
rotate: false
|
||||
xy: 704, 930
|
||||
xy: 968, 945
|
||||
size: 30, 73
|
||||
orig: 30, 73
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
warriors
|
||||
rotate: false
|
||||
xy: 590, 466
|
||||
size: 66, 126
|
||||
orig: 66, 126
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
warriors-stand
|
||||
rotate: false
|
||||
xy: 324, 466
|
||||
size: 264, 126
|
||||
orig: 264, 126
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
|
||||
inside-cafeteria2.png
|
||||
size: 1024,1024
|
||||
format: RGBA8888
|
||||
size: 1024,512
|
||||
format: RGBA4444
|
||||
filter: Nearest,Nearest
|
||||
repeat: none
|
||||
fight-new-assets/fight-1
|
||||
rotate: false
|
||||
xy: 2, 778
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-10
|
||||
rotate: false
|
||||
xy: 2, 2
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-11
|
||||
rotate: false
|
||||
xy: 260, 196
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-12
|
||||
rotate: false
|
||||
xy: 518, 390
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-13
|
||||
rotate: false
|
||||
xy: 260, 2
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-14
|
||||
rotate: false
|
||||
xy: 518, 196
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-2
|
||||
rotate: false
|
||||
xy: 2, 584
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-3
|
||||
rotate: false
|
||||
xy: 260, 778
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-4
|
||||
rotate: false
|
||||
xy: 2, 390
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-5
|
||||
rotate: false
|
||||
xy: 260, 584
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-6
|
||||
rotate: false
|
||||
xy: 518, 778
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-7
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 2, 196
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-8
|
||||
index: 10
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 260, 390
|
||||
xy: 2, 2
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
fight-new-assets/fight-9
|
||||
index: 11
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 518, 584
|
||||
xy: 260, 196
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: -1
|
||||
index: 12
|
||||
fight-new-assets/fight
|
||||
rotate: false
|
||||
xy: 260, 2
|
||||
size: 256, 192
|
||||
orig: 256, 192
|
||||
offset: 0, 0
|
||||
index: 13
|
||||
|
||||
|
Before Width: | Height: | Size: 138 KiB After Width: | Height: | Size: 171 KiB |
|
Before Width: | Height: | Size: 110 KiB After Width: | Height: | Size: 23 KiB |
@@ -11,8 +11,8 @@
|
||||
[play-clj.utils :refer :all]
|
||||
[play-clj.g2d :refer :all]))
|
||||
|
||||
(defn make-fight-entity []
|
||||
(assoc (utils/get-texture "black.png")
|
||||
(defn make-fight-entity [global-atlas]
|
||||
(assoc (utils/atlas->texture global-atlas "black.png")
|
||||
:x 0
|
||||
:y 0
|
||||
:scale-x 21
|
||||
@@ -172,21 +172,19 @@
|
||||
(mapcat #(repeat (- 4 speed) %) xs))
|
||||
|
||||
(defn make [screen]
|
||||
(let [#_#_warriors-stand-sheet (texture! (utils/get-texture "inside-cafeteria/warriors-stand.png") :split 66 126)
|
||||
#_#_warriors-stand (animation 0.2 (for [i [0 0 0 0 0 0 1 1 0 0 1 1 1 0 0 2 2 2 2 3 3 3 0 0 0 2 2 2 ]]
|
||||
(aget warriors-stand-sheet 0 i)))
|
||||
#_#_ladder-guard-sheet (texture! (utils/get-texture "inside-cafeteria/ladder-guard.png") :split 37 87)
|
||||
#_#_ladder-guard-stand (animation 0.1 [(aget ladder-guard-sheet 0 0)])
|
||||
ladder-guard-stand (animation 0.1 [(utils/get-texture "inside-cafeteria/ladder-guard-2.png")])
|
||||
ladder-guard-talk (animation 0.1 [ (utils/get-texture "inside-cafeteria/ladder-guard-2.png")])
|
||||
warriors-stand (utils/make-anim "inside-cafeteria/knights-stand.png" [49 80] 0.6 (take 100 (repeatedly #(rand-int 10))))
|
||||
knight-a-stand (utils/make-anim "inside-cafeteria/knight-a.png" [70 85] 0.2 (flatten [(repeat 3 [(repeat 7 0) (repeat 7 1) (repeat 7 0) (repeat 7 2)]) [3 4 5 6 7 8 9]]))
|
||||
(let [[screen atlas] (utils/acquire-atlas screen "packed/inside-cafeteria.atlas")
|
||||
[screen global-atlas] (utils/acquire-atlas screen "packed/global.atlas")
|
||||
|
||||
|
||||
|
||||
ladder-guard-stand (animation 0.1 [(utils/atlas->texture atlas "ladder-guard-2")])
|
||||
ladder-guard-talk (animation 0.1 [ (utils/atlas->texture atlas "ladder-guard-2")])
|
||||
warriors-stand (utils/make-anim atlas "knights-stand" [49 80] 0.6 (take 100 (repeatedly #(rand-int 10))))
|
||||
knight-a-stand (utils/make-anim atlas "knight-a" [70 85] 0.2 (flatten [(repeat 3 [(repeat 7 0) (repeat 7 1) (repeat 7 0) (repeat 7 2)]) [3 4 5 6 7 8 9]]))
|
||||
|
||||
|
||||
|
||||
#_#_ladder-guard-talk (animation 0.2 (for [i [0 0 0 0 1 0 0 1]]
|
||||
(aget ladder-guard-sheet 0 i)))
|
||||
hands-fight-win (utils/make-anim-seq "inside-cafeteria/fight-new-assets/fight" [256 192] 0.025 (flatten [(pace [0 1 0 4 0 1 0 4 0 1 0 4 0 1 0 4 0 1 0 4 0 0 1 1 1 1 0 0 0 4 0 1 1 1 1 1 1 1 1 4 0 4 0 4 0 4 5 5 5 5 5 4 4 4] 0)
|
||||
hands-fight-win (utils/make-anim-seq atlas "fight-new-assets/fight" [256 192] 0.025 (flatten [(pace [0 1 0 4 0 1 0 4 0 1 0 4 0 1 0 4 0 1 0 4 0 0 1 1 1 1 0 0 0 4 0 1 1 1 1 1 1 1 1 4 0 4 0 4 0 4 5 5 5 5 5 4 4 4] 0)
|
||||
(pace (flatten (repeat 6 [12 13])) 0)
|
||||
(pace (flatten (repeat 15 [7 8])) 0)
|
||||
(pace (flatten (repeat 15 [9])) 0)
|
||||
@@ -202,7 +200,7 @@
|
||||
(pace (flatten (repeat 6 [12 13])) 0)
|
||||
|
||||
(pace [0 0 0 0 2 1 1 2 2 1 1 2 2 2 1 1 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3] 0)]))
|
||||
hands-fight-lose (utils/make-anim-seq "inside-cafeteria/fight-new-assets/fight" [256 192] 0.1 (flatten [4 4 4 4 4 4 0 0 0 0 4 4 4 0 0 0 5 5 5 6 6 6 6 6 6]))]
|
||||
hands-fight-lose (utils/make-anim-seq atlas "fight-new-assets/fight" [256 192] 0.1 (flatten [4 4 4 4 4 4 0 0 0 0 4 4 4 0 0 0 5 5 5 6 6 6 6 6 6]))]
|
||||
(rooms/make :music :town-1
|
||||
:name "Cafeteria"
|
||||
:interactions
|
||||
@@ -214,10 +212,10 @@
|
||||
(actions/walk-to entities :ego [126 80] :skip-type :end))
|
||||
:cursor :right}
|
||||
}
|
||||
:layers [(assoc (utils/get-texture "inside-cafeteria/background.png") :x 0 :y 0 :baseline 0)
|
||||
(assoc (utils/get-texture "inside-cafeteria/doorway.png") :x 306 :y 34 :baseline 202)
|
||||
(assoc (utils/get-texture "inside-cafeteria/glow.png") :y 0 :baseline 240 :additive? true :opacity 0.3)
|
||||
(assoc (utils/get-texture "inside-cafeteria/fg.png") :x 10 :y 0 :scale-x 1.1 :scale-y 1.0 :baseline 320 :parallax 1.5)
|
||||
:layers [(assoc (utils/atlas->texture atlas "background") :x 0 :y 0 :baseline 0)
|
||||
(assoc (utils/atlas->texture atlas "doorway") :x 306 :y 34 :baseline 202)
|
||||
(assoc (utils/atlas->texture atlas "glow") :y 0 :baseline 240 :additive? true :opacity 0.3)
|
||||
(assoc (utils/atlas->texture atlas "fg") :x 10 :y 0 :scale-x 1.1 :scale-y 1.0 :baseline 320 :parallax 1.5)
|
||||
]
|
||||
:entities {:warriors (actions/start-animation screen (assoc (animation->texture screen warriors-stand) :x 31 :y 36 :baseline 180
|
||||
|
||||
@@ -265,13 +263,13 @@
|
||||
"Do not durst telleth a soul about that ladder!"
|
||||
"No thank you, young sire."))))
|
||||
:stand)
|
||||
:ladder (assoc (utils/get-texture "inside-cafeteria/ladder.png") :x 205 :y 70 :baseline 170
|
||||
:ladder (assoc (utils/atlas->texture atlas "ladder") :x 205 :y 70 :baseline 170
|
||||
:cursor :hand
|
||||
:label "Ladder"
|
||||
:script (actions/get-script entities
|
||||
(actions/talk entities :ladder-guard "Do not toucheth, young sire.")))}
|
||||
:collision "inside-cafeteria/collision.png"
|
||||
:fight (make-fight-entity)
|
||||
:fight (make-fight-entity global-atlas)
|
||||
:hands-fight (assoc (animation->texture screen hands-fight-win)
|
||||
:origin-x 128
|
||||
:origin-y 96
|
||||
|
||||