UNPKG

comic-bubbles

Version:

Animated comic bubbles - what else?

14 lines (12 loc) 354 B
export class BubbleDeviation { constructor() { this.bodyX = this.getRandom(0) this.bodyY = this.getRandom(0) this.connectorX = this.getRandom(0) this.arrowY = this.getRandom(0) } getRandom(value) { return Math.floor(Math.random() * (value * 2 + 1)) - value } } export let bubbleDeviations = new Array()