Skip to content

Commit dfa678c

Browse files
committed
fix: replace glitchy CSS sprite loader with canvas-driven animation
- Use webp spritesheet (1.4MB) instead of png (16MB) - Canvas drawImage with exact pixel coords eliminates sub-pixel jitter - Remove 400 lines of per-frame CSS keyframes - Skip p5 boot sequence, go straight to site after loader
1 parent 826758f commit dfa678c

3 files changed

Lines changed: 44 additions & 365 deletions

File tree

2026/sketch.js

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ let sharedTime = 0;
4141
let shareDiv;
4242

4343
// Hack X states
44-
let booting = true;
45-
let gameEnterAnim = 0; // 0 to 1 fade-in after boot
44+
let booting = false;
45+
let gameEnterAnim = 1; // skip boot — game ready immediately
4646
let gameEnterStart = 0;
4747
let bootFrameCounter = 0;
4848
let bootGlitching = false;
@@ -217,6 +217,13 @@ function setup() {
217217
cnv.drawingContext.willReadFrequently = true;
218218
frameRate(30);
219219

220+
// Hide the HTML boot-loader overlay and enable scrolling
221+
const bootLoader = document.getElementById("boot-loader");
222+
if (bootLoader) bootLoader.classList.add("hide");
223+
document.body.style.overflowY = "auto";
224+
const hint = document.getElementById("scroll-hint");
225+
if (hint) hint.style.opacity = "1";
226+
220227
// create a downscaled graphics buffer to draw to, we'll upscale after applying crt shader
221228
g = createGraphics(windowWidth, windowHeight);
222229
g.drawingContext.willReadFrequently = true;

0 commit comments

Comments
 (0)