ericrkern.com
Résumé
AI-generated image of Eric Kern in a futuristic command center

ERIC KERN

Inventor. Builder. Founder.

I've spent my life turning emerging technologies into things people can actually use.

Technology · Architecture · AI · Game development

Behind the Games: From Classic Gaming to AI-Powered Development

Eight classic games rebuilt to run in a web browser, written in TypeScript with human direction and AI-assisted development. This page describes only what the source code actually contains, from an audit on 30 November 2026.

  • 8playable games
  • 260+automated test cases
  • 380+commits since Aug 2026
  • 55original synthesized pieces

Why these games

From a friend’s Apple II to the browser

At thirteen, in eighth grade, Eric played Wizardry and Ultima on a friend’s Apple II. At fourteen he got a ColecoVision for Christmas and played Defender. At eighteen he played The Bard’s Tale on his college roommate’s Commodore Amiga. He also rode his bike with friends to a store to play Commando, feeding the machine quarter after quarter.

Those machines had a few kilobytes of memory. Today a browser tab can run a WebGL 2 dungeon, a synthesized orchestra and six cooperating AI adventurers. The collection is an experiment in what changes when one person directs the design and AI tools help write the code, art and documentation. It also asks what has to stay the same: the clear rules and tight controls that made the originals great.

Personal memories come from Eric. Dates and models of the machines are not confirmed. Read the full journey →

Verified from package.json and source imports

Languages and technology inventory

TypeScript

Every game engine, rule set, AI planner, save schema and React component.

Strict typed campaign state, character attributes, monster tables, dungeon grids, combat rounds, utility-AI scoring and Zod-validated saves.

TSX (React)

Game shells, menus, party panels, overlays and the website itself.

Thin components such as WizardryGame and BardsTaleGame drive React-free engines and display their state.

CSS (Tailwind CSS 4 + hand-written stylesheets)

Responsive layouts, fullscreen single-screen game shells, touch controls and animation.

Measured visual-viewport shells, pointer-based touch-only controls, framed battle portraits, Bard song bursts.

HTML5

Document structure plus <canvas> drawing surfaces and native <img> artwork layers.

Canvas 2D arcade playfields; WebGL canvases for the 3D games; HTML monster portraits kept outside 3D scaling for sharpness.

Python

Development tooling only — never shipped to visitors.

Playwright scripts in scripts/ that capture museum screenshots and check Wizardry viewports, camping, monsters and navigation.

GLSL

Only through Three.js built-in materials and post-processing passes; no custom shader source was written.

MeshStandardMaterial lighting, SSAO and bloom passes in Wizardry come from Three.js addons.

TechnologyVersionStatusKindWhat it does here
React19.2ImplementeddirectUser interface for the site and every game shell.
TanStack Start / Router1.168 / 1.170ImplementeddirectFile-based routes, server rendering, per-page search metadata.
Vite8.1ImplementeddirectDevelopment server, bundling and code-splitting (3D renderers load only during play).
Tailwind CSS4.2ImplementeddirectStyling system and responsive utilities.
Radix UI / shadcn-style components—ImplementeddirectAccessible dialogs, popovers, sliders and menus.
Lucide icons0.575ImplementeddirectInterface icons in game toolbars.
Three.js0.187ImplementeddirectWebGL 3D rendering for Wizardry, The Bard’s Tale and Operation Thunderstrike: GLTF models, skeletal animation of licensed models, PBR materials, post-processing.
rot.js2.2ImplementeddirectSeeded random-number generator for the two party RPG rule engines (reproducible combat).
Zod3.24ImplementeddirectValidates and migrates saved campaigns so old saves keep loading.
Canvas 2D—Implementedbrowser APIArcade games, Ultima’s world, retro fallbacks and minimaps.
WebGL 2—Implementedbrowser APIWizardry’s adaptive renderer; WebGL in the other 3D games.
Web Audio API—Implementedbrowser APIAll game sound: arcade effects and the synthesized adaptive RPG soundtrack.
Gamepad API—Implementedbrowser APIController input for arcade games, Ultima, Thunderstrike and the RPG joystick layer.
localStorage / IndexedDB—Implementedbrowser APISaves, scores and preferences stay on the player’s device (IndexedDB for Wizardry campaigns).
Vitest + Bun testVitest 4Implementeddirect267 automated rule, AI, save-migration and data tests across the games.
Playwright (Python)—ImplementedplatformBrowser checks and screenshot capture during development.
ESLint / TypeScript compiler—ImplementeddirectStatic checks on every change.
Lovable Cloud—ImplementedplatformHosts the website’s private areas; the games themselves do not use the database.
WebGPU—Not usedbrowser APINot used; Wizardry targets WebGL 2.
React Three Fiber / Drei—Not useddirectNot used; Three.js is driven directly from React-free renderer classes.
Howler.js / Tone.js—Not useddirectNot used; audio is written directly on the Web Audio API.
Physics engine / Redux / Zustand—Not useddirectNot used; collisions are custom, state lives in plain typed objects and React state.
GitHub Actions / CI—Not usedplatformNo CI workflow exists in the repository.

The site also uses form, chart, email and carousel libraries that have nothing to do with the games. They are left out of this inventory.

How the pieces fit

One architecture, two kinds of game

PresentationReact components: menus, party panels, portraits, minimaps, touch joystick, popovers
RenderingCanvas 2D for arcade games, Ultima and fallbacks · lazy-loaded Three.js/WebGL for the 3D games · HTML portrait layers
Gameplay enginesReact-free TypeScript modules: movement, collision, combat rounds, progression, navigation, treasure
AIRule-based enemies · utility agents (Wizardry) · legal-action planner (Bard’s Tale)
AudioShared Web Audio engine: adaptive music, ambience, effects, Bard phrases
PersistenceZod-validated saves in IndexedDB or localStorage, with migrations
PlatformBrowser · keyboard, touch, Gamepad API · measured viewport shells · WebGL capability probing

Arcade loop

  1. 1Keyboard / touch / gamepad input
  2. 2Fixed-step simulation (velocity, inertia, wrap-around)
  3. 3Collision and rules (scoring, power-ups, waves)
  4. 4Canvas 2D draw each animation frame

RPG turn

  1. 1Player or AI chooses a legal action
  2. 2Seeded rules engine (rot.js RNG) resolves the round
  3. 3Validated campaign state is saved
  4. 4Renderers, portraits and audio read the result. They never write back.

Interactive

Technology explorer

Space Invaders adaptation

Inspired by
Space Invaders · Tomohiro Nishikado · Taito · 1978
Rendering
Canvas 2D fixed-step engine
Artificial intelligence
Rule-based formation movement, firing and boss patterns
Input
Keyboard, touch buttons, Gamepad API
Audio
Synthesized Web Audio effects
Saves
Local high scores, achievements, settings
Artwork
Drawn in code
Notes
Four modes, power-ups and bosses. Shared online leaderboard not built.
Source & tests
≈64 KB of game-module TypeScript · 1 test file
Play it →
Space Invaders adaptation — actual gameplay capture
Actual capture from this website’s browser edition.

Comparison matrix

GameCanvas 2DThree.js / WebGLAutonomous AIAdaptive musicTouch controlsGamepadLocal savesLicensed 3D modelsGenerated artwork
Space Invaders adaptation✓———✓✓✓——
Asteroids adaptation✓———✓✓✓——
Defender adaptation✓———✓✓✓——
Robot Uprising: 2186✓———✓✓✓——
Labyrinth of the Fallen King✓✓✓✓✓✓✓✓✓
Ultima adaptation✓———✓✓✓——
The Ballad of Eternal Winter✓✓✓✓✓✓✓✓✓
Operation Thunderstrike✓✓——✓✓✓✓Partial

Major feature

Autonomous party AI

Labyrinth of the Fallen King

Each adventurer is a utility agent. It scores the actions it is allowed to take, such as attacking, casting, healing or defending, by threat, injury and the resources it has left. A coordinator reserves targets and heals so effort isn’t wasted. Players can choose a strategy, override any adventurer, or switch to manual.

The Ballad of Eternal Winter

A deterministic planner picks only legal actions for each round. It uses no random numbers and doesn’t change the game state itself. It has six strategies (Balanced, Aggressive, Defensive, Conserve Magic, Boss Battle, Survival). It saves Bard songs for hard fights, shares healing between healers, and warns before likely defeat.

Party coordinatorreservations · priorities · strategy

Front rank: scores melee value against the most threatening group

Every choice is submitted as a legal action to the same round engine as manual play. Agents never change statistics, dice or quest progress. All of this is rule-based scoring in TypeScript, not a language model.

Generated, licensed and procedural, labeled separately

How the graphics were made

  1. 1Written creature description from the game data
  2. 2Image generated with Lovable’s image tool
  3. 3Cropped, compressed to WebP, stored on the asset CDN
  4. 4Catalogued by monster ID in TypeScript
  5. 5Shown in a gold frame during a real encounter

The 3D games use CC0 models from Quaternius and CC0 textures from Poly Haven. Wizardry’s renderer adjusts resolution, shadows and effects to the frame rate it measures, with SSAO and bloom passes from Three.js. Monster portraits are flat illustrations, not rigged 3D characters. The licensed models have skeletal animation but represent several creatures each. Arcade graphics are drawn entirely in code.

Performance in the development sandbox was measured with software rendering, about 1–2 frames per second. That is not a device benchmark. No 60 FPS or 4K claim has been verified.

Galactic Defense: Inside the browser game
Galactic Defense · actual browser capture
Asteroid Assault: Inside the browser game
Asteroid Assault · actual browser capture
Humanity’s Last Stand: Inside the browser game
Humanity’s Last Stand · actual browser capture
Chronicles of Eternity: Inside the browser game
Chronicles of Eternity · actual browser capture
Labyrinth of the Fallen King: Inside the browser game
Labyrinth of the Fallen King · actual browser capture
Robot Uprising: 2186: Inside the browser game
Robot Uprising: 2186 · actual browser capture
Operation Thunderstrike: Inside the browser game
Operation Thunderstrike · actual browser capture
The Ballad of Eternal Winter: Inside the browser game
The Ballad of Eternal Winter · actual browser capture

Original, synthesized live

How the game music was created

There are no audio files. Each of the 55 pieces is a short set of instructions: key, mode, tempo, chord progression and instruments. The browser’s Web Audio API turns these into sound with simple models of harp, strings, flute, fiddle, horns, organ and choir, plus synthesized drums and reverb. Melodies are generated from a fixed seed, so each piece is recognisable but varies on every loop. The six Bard songs each have their own phrase, played in the key of the music already playing.

  1. 1Visible game state (place, floor, battle, party health)
  2. 2Music-state resolver picks a piece and intensity
  3. 3Crossfade and intensity layers
  4. 4Event diffing triggers cues and effects
  5. 5Mixer: master, music, effects, environment
  • Labyrinth of the Fallen KingLabyrinth of the Fallen King · main menu · 70 bpm · horn lead
  • The Royal FortressLabyrinth of the Fallen King · castle exploration · 84 bpm · horn lead
  • The Warden’s MazeLabyrinth of the Fallen King · dungeon level 5 · 64 bpm · horn lead
  • Creatures in the DarknessLabyrinth of the Fallen King · standard combat · 138 bpm · strings lead
  • The Fallen King’s SorcererLabyrinth of the Fallen King · final boss · 126 bpm · organ lead
  • The Ballad of Eternal WinterThe Ballad of Eternal Winter · main menu · 76 bpm · soprano lead
  • Streets of WinterhavenThe Ballad of Eternal Winter · city exploration · 96 bpm · fiddle lead
  • The Singing TavernThe Ballad of Eternal Winter · tavern · 126 bpm · whistle lead
  • Swords and SongsThe Ballad of Eternal Winter · standard combat · 144 bpm · fiddle lead
  • The Sorcerer’s WarThe Ballad of Eternal Winter · final boss · 132 bpm · pipes lead

Nothing plays until you press Play. These are live synthesizer renderings of original melodies, not studio recordings.

Registry: 30 Wizardry pieces, 25 Bard’s Tale pieces, 6 Bard song phrases. No commercial game music was copied.

Human-directed AI collaboration

How Lovable and ChatGPT were used

Lovable

Lovable, an AI software agent, wrote and changed the code in response to Eric’s plain-language briefs. It also generated artwork, ran automated tests and browser checks, and committed each change to Git: more than 380 commits since August 2026. Briefs often asked for more than one pass could deliver, so each reply listed what was done, what was checked and what was left. Those lists shaped the next brief.

ChatGPT

Eric used ChatGPT to help draft the long design briefs, like the one that produced this page. The games do not call ChatGPT or any language model while you play. All in-game AI is rule-based TypeScript.

  1. 1Eric’s idea and memories
  2. 2Brief drafted with ChatGPT
  3. 3Lovable audits code, builds, tests
  4. 4Browser checks at phone and desktop sizes
  5. 5Eric plays, reviews and asks for corrections

Real fixes from the project history

Engineering case studies

Doors and stairs that didn’t connect

Problem. Wizardry doors and stairs looked open but movement rules disagreed, stranding parties.

Solution. Navigation became the single owner of doors and reciprocal stairs, with a breadth-first search validator across all ten floors that renderers and minimaps read.

Result. Level 1 to Level 2 descent and return verified with on-screen controls; old saves relocate safely.

Faceless figures and pixelated monsters

Problem. Humanoid monsters reused one faceless model; textured standees blurred under adaptive resolution.

Solution. Battles stopped building 3D creatures and show native HTML portraits outside the WebGL canvas.

Result. Sharp, framed portraits at phone and desktop sizes; 3D models kept only for the optional bestiary.

Leveling that never happened

Problem. The Training Grounds had no level-up action; levels only applied silently at the Inn.

Solution. One React-free progression module now serves training, inn and camp.

Result. One-tap multi-level training verified in a phone-sized browser; thresholds can no longer diverge.

A game that scrolled off the phone

Problem. The Bard’s Tale world used 37% of a portrait phone and the page scrolled 354 px.

Solution. A fixed fullscreen shell with floating docks and pinned battle buttons.

Result. 82–92% of the screen across 11 tested sizes with no scrolling.

Where every asset came from

Asset provenance and licensing

AssetCountSourceLicense
Monster & adventurer portraits (Wizardry)66 monsters · 80 adventurersGenerated with Lovable’s image tool from written descriptionsGenerated for this site; usage rights follow the generating service’s terms
Creature portraits & interiors (Bard’s Tale)80 creatures · 6 interiorsGenerated with Lovable’s image toolAs above
3D models (village, knight, enemies)20 GLB filesQuaternius packsCC0
PBR stone, cobblestone and wood texturesOriginal 1K plus 24 2K/4K variantsPoly HavenCC0
Museum screenshotsPer game: gameplay, detail, phone, titleCaptured from this site by scripts/capture-games.pyOriginal
Museum illustrations (promo, retro, hardware, era, memory)≈60Generated; labeled as illustrations, never as historical photosGenerated for this site
RPG soundtrack (55 pieces + 6 Bard phrases)0 audio filesOriginal melodies synthesized live in the browserOriginal
Original 1978–1985 game artwork or musicNone—Not included

Commercial-use terms for generated images depend on the generating service’s terms and have not been independently reviewed.

Proposed, not built

Future engineering

  • Recorded orchestral and vocal soundtrack to replace the synthesized one
  • Rigged 3D characters with faces for adventurers and villagers
  • Shared online leaderboards for the arcade games
  • Physical iPhone, Safari and GPU performance testing
  • Continuous integration that runs the tests on every commit