mirror of
https://github.com/xvvvyz/tilde.git
synced 2026-03-11 14:44:24 +00:00
reduce unwanted rain streaking
This commit is contained in:
parent
e6ffda0820
commit
5c980bca70
1 changed files with 5 additions and 1 deletions
|
|
@ -18,7 +18,6 @@
|
|||
--font-weight-bold: 700;
|
||||
--font-weight-normal: 400;
|
||||
--line-height-base: 1.4;
|
||||
--rain-columns: 150;
|
||||
--space-1: 0.5rem;
|
||||
--space-2: 1rem;
|
||||
--space-3: 4rem;
|
||||
|
|
@ -793,6 +792,11 @@
|
|||
this.#size = Math.ceil(this.#canvas.width / CONFIG.rainColumns);
|
||||
this.#backgroundColor = Rain.cssVar('--color-background');
|
||||
this.#rainColor = Rain.cssVar('--color-rain');
|
||||
this.#ctx.fillStyle = this.#rainColor;
|
||||
this.#ctx.fillRect(0, 0, this.#canvas.width, this.#canvas.height);
|
||||
this.#ctx.fillStyle = this.#backgroundColor;
|
||||
this.#ctx.globalAlpha = 0.9;
|
||||
this.#ctx.fillRect(0, 0, this.#canvas.width, this.#canvas.height);
|
||||
this.#drops = new Array(CONFIG.rainColumns).fill(0);
|
||||
this.#frameCount = 0;
|
||||
this.#lastRender = performance.now();
|
||||
|
|
|
|||
Loading…
Reference in a new issue