Fix rewind effect to go up, not down

This commit is contained in:
Eevee (Evelyn Woods) 2020-09-16 19:57:17 -06:00
parent ede7dbf424
commit 171c52acb5

View File

@ -137,8 +137,8 @@ export class CanvasRenderer {
} }
draw_rewind_effect(tic) { draw_rewind_effect(tic) {
// Shift several rows over // Shift several rows over in a recurring pattern, like a VHS, whatever that is
let rewind_start = 1 - tic / 20 % 1; let rewind_start = tic / 20 % 1;
for (let chunk = 0; chunk < 4; chunk++) { for (let chunk = 0; chunk < 4; chunk++) {
let y = Math.floor(this.canvas.height * (chunk + rewind_start) / 4); let y = Math.floor(this.canvas.height * (chunk + rewind_start) / 4);
for (let dy = 1; dy < 5; dy++) { for (let dy = 1; dy < 5; dy++) {