← All entries

Dev Log

Build notes from the Jefe ecosystem

Adventure GUI: 7,100 Lines in One Night

The Game Forge 2026-04-03

Two commits, 48 files changed, ~7,100 lines of new code and content. The Adventure GUI went from "working prototype with a basic chat interface" to "complete character creation system with a grimoire-themed frontend and three ready-to-play campaigns." Executed a 6-phase sprint plan followed by a 4-agent parallel extended sprint, all in one session.

The Core Sprint: Character System Foundation

The first commit delivered the entire character system in 6 sequential phases. Phase 1 fixed a normalization bug where getCampaign() was passing the raw API wrapper {campaign: {...}, portraits: [...]} to the normalizer instead of extracting the campaign object. Then expanded the TypeScript types with 13 new interfaces covering skills, spell slots, equipment, death saves, and stat generation methods, plus 7 new API client functions. Phase 2 extracted all D&D 5e data (9 races, 12 classes, 12 backgrounds, 18 skills, point buy costs) from the old tkinter GUI into a pure Python data module with zero GUI imports, then added 8 new FastAPI endpoints for character CRUD and reference data. The derived stat calculations (HP, AC, initiative, proficiency, skill modifiers) are all server-side so the frontend and backend always agree.

Character Creation Wizard

Phase 3 was the heavy lift — a 4-step React wizard replacing the old simple modal. Step 1 handles identity with live race/class previews pulled from the reference API. Step 2 is the stat generation system with four methods: Standard Array (dropdown assignment), Roll 4d6 Drop Lowest (server-side rolls with individual dice display), Point Buy (budget counter with +/- controls), and Manual Entry. Racial bonuses apply in real-time and derived stats (HP, AC, initiative, proficiency) update live as you adjust scores. Step 3 is a skill proficiency picker that auto-grants background skills, filters available choices by class, and shows calculated modifiers. Step 4 is a review page with personality fields.

Character Sheet, DM Mode, Session Resume

Phase 4 added a slide-over character sheet panel with 7 collapsible sections (ability scores, combat with an HP damage/heal widget, skills, equipment, backstory, features, conditions) and auto-save via PUT. Phase 5 introduced DM/Player mode with a React context, localStorage persistence per campaign, and a toggle in both page headers — DM mode adds a gold accent bar and will eventually control NPC visibility and quest spoilers. Phase 6 added markdown rendering in the game log (bold, italic, blockquotes for DM messages), session resume that loads existing transcript on page mount, active character persistence, and an error boundary.

The Extended Sprint: Four Agents in Parallel

After committing the core sprint, four specialized agents launched simultaneously:

AgentDeliverable
Game DeveloperEpic dice roller with 3D CSS tumble animations, three keyframe variants for multi-dice, screen-shake + gold particle crits, red glow + crack overlay fumbles
Web DeveloperGrimoire landing page — leather-bound book layout with stitched spine, quest poster campaign cards with torn edges and wax stamps, animated wax seal "New Campaign" button that cracks open
Adventure Designer #1Three starter campaigns: Goldengloom (enriched flagship with 5 NPCs and metaplot), The Drowned Throne (nautical horror), The First Lantern (beginner-friendly with tutorial integration)
Adventure Designer #210 NPC personality templates with voicing guide — each with speech patterns, secrets, motivations, and DM instructions

The NPC Templates

The 10 archetypes (tavern keeper, mysterious merchant, rival adventurer, corrupt guard, oracle, street urchin, cursed noble, bard, war veteran, fey trickster) are designed with a key principle: every secret creates a moral dilemma, not a binary reveal. The corrupt guard captain takes bribes to fund an orphanage. The cursed noble made a fiendish deal to save his daughter. The bard encodes apocalyptic warnings in song lyrics. Speech patterns are engineered for AI DM differentiation — one never uses contractions, another drops articles, another swears in Draconic. The cross-NPC dynamics mean placing multiple templates in a campaign creates emergent narrative connections.

What's Next

  • Test everything live on Titan — code is pushed, API restart needed
  • Post-sprint testing: Vitest for frontend, Pytest for backend, integration tests for all 4 stat generation methods
  • Wire NPC template data into the DM system prompt (currently only name/role/location are surfaced)
  • Character sheet animations, HP keyboard support, error toasts
  • Backward compatibility testing with existing Goldengloom campaign characters