Three.js · no assets · procedural

Hellgate

A Doom-style 2.5D arena shooter that runs in a browser tab. Sector maps generated from a seed string, three weapons, two enemy types, and not one external asset — every texture is painted on a canvas, every enemy is boxes, every sound is synthesised.

WASD · mouse · 1–3 · esc  |  ~20 MB, loads in a second

01 — what it is

A shooter built out of nothing but code

HELLGATE is a small, complete game: a first-person arena shooter with procedural levels, a real combat loop, and a wave structure that gets harder until you die. It is also a reference for how far you can get in Three.js without loading a single image, model, or audio file.

0external assets
5draw calls / level
2.7ktriangles, a level
3headless test suites
~7.4klines of JS

02 — in the arena

Look at it

Real frames, captured from the game running headless in Chromium. No mockups.

A brick arena with imps and a grunt closing in, pistol equipped
the arena — wave 3, imps and a grunt01
Shotgun blast with blood spray and tracers on an imp
shotgun — 8 pellets, damage falloff02
Rocket explosion lighting up a pack of imps orange
rocket — splash damage and screen shake03
The exit room with its glowing pad and EXIT OPEN message
exit open — cleared wave, unlocked door04

03 — the map is a seed

One string, one arena

Rooms are carved as rectangles, joined by L-shaped corridors, then given random ceiling heights so corridor mouths read as doorways. The exit room gets sealed behind doors, one room gets a raised ledge, and the whole thing is merged into five meshes. Type the same seed twice and you get the same map, down to the brick.

spawn exit pad doors
Top-down map of the hellgate seed: ten rooms joined by corridors, with the exit room sealed behind three doors

04 — how it plays

Clear the wave, open the exit

WAVE 1–2

Imps

Throw fireballs, telegraph the throw, wander until they see you. Wave two adds grunts that close distance and hitscan you at range.

WAVE 3+

The keycard

From wave three the exit is keycard-locked as well as wave-locked: find the yellow card, then clear the room, then leave.

CLASS

Powers

Three classes, five powers on an energy pool: dash, shockwave, ward, volley, bulwark. A companion drone follows you and shoots what it can see.

ALWAYS

Pickups

Health, armour, bullets, shells and rockets are scattered procedurally each wave. Armour eats half of every hit.

FEEL

Feedback

Hit flash on enemies, tracers, wall decals, gibs, a face indicator that degrades, damage arrows, and screen shake on rockets.

controls

W A S Dmove
Shiftsprint
Spacejump
Mouselook
LMBfire
1 2 3pistol / shotgun / rocket
Q Ecycle weapons
Escpause
`fps / draw calls
Q E Rclass powers
Mmute
Ffullscreen

05 — under the hood

Small files, readable code

No bundler, no build step, no framework. ES modules and an import map. The level generator imports nothing, so it can be unit-tested in Node without a browser.

play/src/level.js

Generator + collision

Sector grid, rooms, corridors, doors, circle-vs-wall sliding, wall raycasts. Pure math, no Three.js.

play/src/levelmesh.js

Geometry

Turns the grid into five merged BufferGeometries with hand-built UVs and normals.

play/src/enemies.js

AI

Two enemy types on one FSM: idle, chase, attack, pain, death. Grid line-of-sight, shared geometry.

play/src/effects.js

Feel

Pooled particles, tracers, decals and lights. Nothing allocates per shot.