Dungeon for developers. Rooms are environments, monsters are bugs, loot is data, boss is the legacy system, party is your team.
- JavaScript 100%
| node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709 | ||
| src | ||
| tests | ||
| package.json | ||
| README.md | ||
code-dungeon
Dungeon for developers. Rooms are environments, monsters are bugs, loot is data, boss is the legacy system, party is your team.
Usage
const { Dungeon, PARTY_ROLES } = require('./src/dungeon');
const dungeon = new Dungeon('The Legacy Depths');
dungeon.recruit('Alice', PARTY_ROLES.WARRIOR);
dungeon.recruit('Bob', PARTY_ROLES.MAGE);
dungeon.recruit('Carol', PARTY_ROLES.HEALER);
// Navigate rooms
const exits = dungeon.currentRoom.exits;
dungeon.moveTo(exits[0]);
// Fight monsters
dungeon.fight('Alice', 0);
dungeon.useAbility('Bob', 0);
dungeon.monsterTurn();
console.log(dungeon.dungeonView());
console.log(dungeon.report());
Monsters
- Null Pointer Slime (HP 40) — Sticky null references
- Race Condition Wraith (HP 30, ATK 14) — Unpredictable
- Memory Leak Blob (HP 100) — Never shrinks
- Segfault Dragon (HP 80, ATK 20) — Instant crash
- Dependency Golem (HP 120, DEF 12) — 500 npm packages
- TODO Comment Imp (HP 20) — They swarm
- The Legacy Dragon (Boss) (HP 500, ATK 30) — Final boss
Party
- Warrior (Backend Dev) — HP 120, ATK 18, heavy hitter
- Mage (SRE) — HP 70, ATK 25, glass cannon
- Rogue (Frontend Dev) — HP 85, fast agile fixes
- Healer (DevOps) — HP 95, keeps everyone alive
- Ranger (QA Tester) — HP 80, ranged test volleys