Generate a medieval castle and the town around it. Castle Forge grows a castle precinct, walls, streets, plots, markets and farmland from a seed, then builds the settlement in 3D using procedural kits for towers, gates, houses, churches, mills, bridges and other structures.
| Component | Source |
|---|---|
| Castle, town and countryside generator, kits and viewers | Castle Forge |
| Genome operators, mesh builder, critic and archive | Shared engine |
Use Node.js 22 and npm. From the workspace root:
npm ci --prefix castle-forge
npm run serve --prefix castle-forgePreview bridge-town seed 313, or open the kit viewer or the castle and town viewer. The procedural viewers generate terrain, maps and buildings from a seed. OpenCastle includes 58 procedural kit types.
npm test --prefix castle-forgeStart with llms.txt for the project map and LLM integration guide for executable examples, coordinate conventions, and data boundaries.
OpenCastle’s original source is available under the MIT License. Bundled third-party code and assets retain their own terms. Third-party notices


