UNPKG

tsparticles

Version:

Porting of the abandoned Vincent Garreau's particles.js, converted in TypeScript. Added many new cool features and various bug fixes.

18 lines (17 loc) 442 B
import { Color } from "../Particles/Color"; export class BackgroundMaskCover { constructor() { this.color = new Color(); this.opacity = 1; } load(data) { if (data !== undefined) { if (data.color !== undefined) { this.color.load(data.color); } if (data.opacity !== undefined) { this.opacity = data.opacity; } } } }