Skip to content

Instantly share code, notes, and snippets.

@mauriciomassaia
Created April 19, 2018 03:42
Show Gist options
  • Save mauriciomassaia/48178849dce188d8e887cdacd29120cc to your computer and use it in GitHub Desktop.
Save mauriciomassaia/48178849dce188d8e887cdacd29120cc to your computer and use it in GitHub Desktop.
GSAP + ColorPropsPlugin + Pixi.js
import { TweenMax } from 'gsap'
import 'gsap/ColorPropsPlugin'
const g = new Graphics()
g.beginFill(color, alpha)
g.drawRect(x, y, width, height)
g.endFill()
container.addChild(g)
TweenMax.to(g, 0.5, {colorProps: {tint: 0x00aaff, format: 'number'}})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment