How will99919/the-hyrule-castle works
This is a small TypeScript Zelda-themed RPG. The sampled game entry point creates a randomized player, runs up to ten turn-based fights, and reads attack or heal choices from the terminal; ordinary enemies appear before a final boss. Character growth and saving exist as separate modules, but the sampled game does not wire them into that workflow. Resource files for classes, races, spells, and traps are present, though their runtime use is not established by the sampled code.
Main entry points: mods/hyrule_castle.ts Game runner · save.ts Save module · base_game/hyrule_castle.ts Base game entry · players.json Player roster
Components 15
Game flow
- Game runner
mods/hyrule_castle.ts - Character setup
mods/hyrule_castle.ts - Combat loop
mods/hyrule_castle.ts - Base game entry
base_game/hyrule_castle.ts
Game data
- Player roster
ressources/players.json - Enemy roster
ressources/enemies.json - Boss roster
ressources/bosses.json - Class data
ressources/classes.json - Race data
ressources/races.json - Spell data
ressources/spells.json - Trap data
ressources/traps.json
Extensions
- Experience system
mods/experience_system.ts - Save module
mods/save.ts
Other components
- Player
- Terminal input
Connections 9
- Player → Game runner: starts
- Game runner → Character setup: creates player
- Character setup → Player roster: selects from
- Game runner → Combat loop: runs fights
- Game runner → Enemy roster: selects enemies
- Game runner → Boss roster: selects final boss
- Combat loop → Terminal input: prompts actions
- Terminal input → Combat loop: returns choice
- Save module → Base game entry: imports