Created
October 8, 2016 04:54
-
-
Save Polyrhythm/e3a6688403a33841760edd55a7cecb33 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns game.scenes.one-two.core) | |
(defn glitch [duration] | |
(timeline [(tween {:analog-glitch {:color-drift 0.3 :scanline-jitter 0.3}} Camera/main duration) | |
(tween {:analog-glitch {:color-drift 0 :scanline-jitter 0}} Camera/main duration)]))) | |
(defn init-scene [] | |
(setup-scene)) | |
(deftween [:analog-glitch :color-drift] [this] | |
{:get (.colorDrift this) | |
:base (a/cmpt this AnalogGlitch) | |
:base-tag AnalogGlitch | |
:tag System.Single}) | |
(deftween [:analog-glitch :scanline-jitter] [this] | |
{:get (.scanLineJitter this) | |
:base (a/cmpt this AnalogGlitch) | |
:base-tag AnalogGlitch | |
:tag System.Single}) | |
;========================== | |
(ns game.scene-manager | |
(:require [game.scenes.one-two.core :as one-two]) | |
(defn start-game []) | |
(hook+ some-obj :start #start-game) | |
; invoked only by the REPL ^^ | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment