DRIVING SIMULATOR

A birds-eye-view slalom driving test

Play Now

Press Enter or Space to start

Controls

ActionKeyRange
Throttle Up=0 – 10
Throttle Down-0 – 10
Brake UpA0 – 5
Brake DownZ0 – 5
Steer Left-10 to 10
Steer Right-10 to 10
RestartR

All controls are tap-to-set — each press adjusts the value by 1 step. Steering stays at the set angle until changed.

Scoring

Weave between the centre-line cones to collect gates and maximise your score. Reach the chequered finish line to complete the course.

Vehicle Configuration

Power
Affects acceleration rate — higher power reaches target speed faster
Weight
Affects braking performance — heavier vehicles carry more momentum and brake slower
Turning Circle
Affects steering responsiveness — higher values give tighter, more responsive turns

Default configuration: Power 5, Weight 5, Turning Circle 5. The throttle sets a target speed (each level = 15 px/s), and the vehicle accelerates toward it based on power.

The Engine

Built on pb-galaga engine patterns — decoupled game logic and rendering for clean architecture and headless testing.

Language
TypeScript (strict mode)
Rendering
Canvas 2D — no framework
Audio
Procedural synthesis (Web Audio API)
Physics
60 Hz fixed timestep with interpolation
Build
15 KB single-file — zero runtime dependencies
Testing
75 unit tests (Vitest, headless)