Hi all! This is the devlog thread for HORDEFALL, my 3D top-down zombie horde shooter (three.js + Electron, Windows). It just went into Early Access, and I'll keep posting progress here.

Devlog #1: hunting down the "random" freezes
In testing, the game felt laggy, especially in the menu. The odd part: the average FPS was fine. So I logged every single frame plus CPU and GPU use, and the problem wasn't slow frames at all. It was one-off freezes of 0.3 to 4 seconds.
The cause: on Windows, Chromium draws through ANGLE on D3D11, and every new kind of effect needs a GPU shader built the first time it shows up. That covers every CSS blur size, gradient, mask and blend mode in my menus, and every three.js material. Each build stalled the GPU for up to a second, and Electron throws that shader cache away when you quit.
What fixed it:
- At boot, behind the loading screen, I draw every costly CSS effect once on tiny almost-invisible divs (358 effects in about 1.3 s), so the shaders exist before you open a menu.
- Bosses are now built hidden and compiled in the background during the WARNING screen, not on the first frame they appear.
- Auto graphics quality never switches mid-fight any more, only on card, shop or pause screens. A quality switch recompiles every lit material.
- The menu and HUD 2D canvases moved to the CPU, so they need no GPU shaders.
Result in my 400-zombie + bosses test: total freeze time went from 55 s to 3 s, and the horde fight went from 11 FPS to 80 FPS. First-launch menu stutter was cut roughly in half.

Next up: more CPU work for low-end PCs (turrets are currently a lot of draw calls), then balance based on your feedback.
Trailer, if you want to see it in motion:
Game page: https://lostplaystudio.itch.io/hordefall. Questions about the three.js/Electron side are welcome!