Skip to content

Instantly share code, notes, and snippets.

@shiraleeana
Created March 17, 2014 04:05
Show Gist options
  • Save shiraleeana/9593838 to your computer and use it in GitHub Desktop.
Save shiraleeana/9593838 to your computer and use it in GitHub Desktop.
randomDegree(a=-90deg,b=90deg)
math(math(0, 'random')*(b - a + 1) + a, 'floor')
randomX(a=-100px,b=100px)
math(math(0, 'random')*(b - a + 1) + a, 'floor')
randomY(a=-100px,b=100px)
math(math(0, 'random')*(b - a + 1) + a, 'floor')
randomScale(a=0.1,b=5.0)
math(math(0, 'random')*(b - a + 1) + a, 'floor')
.somethingRandom
-webkit-transform translate(randomX(), randomY()) rotate(randomDegree()) scale(randomScale())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment