android and ios achievements.
This commit is contained in:
@@ -393,6 +393,15 @@
|
||||
|
||||
save-object
|
||||
(#(utils/add-actor-to-stage screen %)))
|
||||
|
||||
:google-play (doto (assoc (image-button (BaseDrawable.)) :x 1150 :y 160 :scale-x 4 :scale-y 4 :origin-x 0 :origin-y 0 :z 10 :key :google-play)
|
||||
|
||||
(image-button! :add (doto (Group. )
|
||||
(.addActor (:object (doto (image (utils/atlas->texture title-atlas "google-play.png"))
|
||||
(image! :set-scale 4))))))
|
||||
|
||||
save-object
|
||||
(#(utils/add-actor-to-stage screen %)))
|
||||
:logo (assoc (utils/atlas->texture title-atlas "logo.png" ) :x 640 :y 960 :scale-x (/ 4 utils/ui-scale) :scale-y (/ 4 utils/ui-scale) :origin-x 160 :origin-y 240 :z 6)
|
||||
:fade (assoc (utils/atlas->texture global-atlas "black.png")
|
||||
:scale-x 80
|
||||
@@ -537,6 +546,15 @@
|
||||
(assoc :chapters-menu (->> (chapters-menu )
|
||||
(utils/add-actor-to-stage screen))))
|
||||
|
||||
|
||||
(= :google-play actor-key)
|
||||
(utils/platformify
|
||||
entities
|
||||
(do
|
||||
(.showAchievements (advent.core.GooglePlay.) (Gdx/app))
|
||||
entities)
|
||||
entities)
|
||||
|
||||
(= :settings actor-key)
|
||||
(-> entities
|
||||
(utils/remove-actor-from-stage :main-menu)
|
||||
|
||||
Reference in New Issue
Block a user