Beginning to get IOS, Android, and Desktop all working at once. Re-enabling steam.

This commit is contained in:
Bryce Covert
2020-01-07 22:18:35 -08:00
parent 7152acd658
commit d1a898035d
11 changed files with 582 additions and 457 deletions

View File

@@ -94,6 +94,7 @@
(utils/play-music (:pop-music entities))
(-> entities
(assoc-in [:pop-logo :anim-start] (:total-time screen))
(assoc-in [:pop-logo :opacity] 1.0)
(assoc-in [:pop-logo :anim] (get-in entities [:pop-logo :main-anim]))))
:duration 10.0}]))
@@ -112,12 +113,17 @@
:on-show
(fn [screen entities options]
(let [[screen splash-atlas] (utils/acquire-atlas screen "packed/splash.atlas")
[screen global-atlas] (utils/acquire-atlas screen "packed/global.atlas")]
[screen global-atlas] (utils/acquire-atlas screen "packed/global.atlas")
[screen pop-logo-atlas] (if utils/mobile?
[screen nil]
(utils/acquire-atlas screen "packed-pop-logo/pack.atlas"))]
(utils/setup-viewport screen 1280 960)
(log/info "Starting splash screen.")
(graphics! :set-cursor (utils/cursor "cursor.png" :hourglass))
(let [screen (assoc screen :total-time 0)
pop-anim (make-anim-seq splash-atlas "POPPixelLogo_02" [320 240] 0.05 (repeat 200 0))
pop-anim (if utils/mobile?
(make-anim-seq splash-atlas "POPPixelLogo_02" [320 240] 0.05 (repeat 200 0))
(make-anim-seq pop-logo-atlas "POPPixelLogo_02" [320 240] 0.05 (range 200)))
entities {:background (assoc (utils/atlas->texture global-atlas "black.png")
:scale-x 80
:scale-y 80
@@ -126,12 +132,12 @@
:origin-y 0
:z 0)
:pop-logo (assoc (animation->texture screen pop-anim)
:anim pop-anim
:main-anim pop-anim
:x 0 :y 0
:origin-x 0 :origin-y 0
:scale-x 4 :scale-y 4
:z 1
:opacity (if utils/mobile? 0.0 1.0))
:opacity 0.0)
:dbhlogo (assoc (utils/atlas->texture splash-atlas "dbh.png") :x 0 :y 0 :origin-x 0 :origin-y 0 :scale-x 4 :scale-y 4 :z 1 :opacity 0.0)
:steps steps
:pop-music (utils/make-music "music/POPPixelLogo2Audiomix_mixdown.ogg")
@@ -144,7 +150,10 @@
:on-render
(fn [{:keys [^FitViewport viewport] :as screen} entities options]
#_(steam/update)
(utils/platformify
nil
nil
(steam/update))
(.apply viewport)
(clear!)
(let [entities (utils/apply-tweens screen entities (:tweens entities))