Example #1
0
const Circle = function (x, y, options) {
  this.x = x;
  this.y = y;
  this.color = options.color[Math.floor(Math.random() * options.color.length)];
  this.radius = anime.random(...options.radius);
  this.distance = options.distance;
};
Example #2
0
const Dot = function (x, y, options) {
  this.x = x;
  this.y = y;
  this.color = options.color; // TODO: This gets customized later
  this.radius = anime.random(...options.radius); // TODO: This gets customized later
};
Example #3
0
			duration: () => {
				return Anime.random(500, 750);
			},
Example #4
0
			delay: () => {
				return Anime.random(0, 100);
			},
Example #5
0
			rotate: () => {
				return Anime.random(-900, 900) * animateEntropy;
			},
Example #6
0
			scale: () => {
				return Anime.random(5, 30) * animateEntropy / 10;
			},
Example #7
0
			translateY: () => {
				let num = 3 * animateEntropy;
				return Anime.random(num * -1, num) * animateEntropy + 'rem';
			},