Files
the-sunken-reach/frontend/src/lib/classData.ts
T
joshuaandClaude Opus 5.5 94067f1268 V1.0.1: Aldenfell campaign seed, content library, party overview
- Seed now resets the database and seeds the Aldenfell campaign from the
  campaign book: admin DM user, default weapons, locations, bestiary,
  pre-built encounters, and DM/shared notes
- Default weapon/spell/monster library, character profile fields,
  locations and dice mode (new migration)
- Party overview page, pagination, info tips, build preview calc
- Remove stale demo-login hint; notes preserve line breaks

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-23 10:24:48 +02:00

50 lines
1.2 KiB
TypeScript

import type { Ability, CharacterClass } from '../api/types';
// Mirrors backend/src/game/data/classes.js — used only to preview the
// running math live during the builder. The server recomputes authoritatively
// at finalize, so this duplication is display-only and never gameplay-deciding.
export const CLASS_SPELLCASTING_ABILITY: Record<CharacterClass, Ability | null> = {
FIGHTER: null,
BARBARIAN: null,
ROGUE: null,
RANGER: 'WIS',
WIZARD: 'INT',
SORCERER: 'CHA',
CLERIC: 'WIS',
PALADIN: 'CHA',
BARD: 'CHA',
WARLOCK: 'CHA',
DRUID: 'WIS',
MONK: null,
};
export const CLASS_HIT_DIE: Record<CharacterClass, number> = {
FIGHTER: 10,
BARBARIAN: 12,
ROGUE: 8,
RANGER: 10,
WIZARD: 6,
SORCERER: 6,
CLERIC: 8,
PALADIN: 10,
BARD: 8,
WARLOCK: 8,
DRUID: 8,
MONK: 8,
};
export const CLASS_SAVE_PROFICIENCIES: Record<CharacterClass, Ability[]> = {
FIGHTER: ['STR', 'CON'],
BARBARIAN: ['STR', 'CON'],
ROGUE: ['DEX', 'INT'],
RANGER: ['STR', 'DEX'],
WIZARD: ['INT', 'WIS'],
SORCERER: ['CON', 'CHA'],
CLERIC: ['WIS', 'CHA'],
PALADIN: ['WIS', 'CHA'],
BARD: ['DEX', 'CHA'],
WARLOCK: ['WIS', 'CHA'],
DRUID: ['INT', 'WIS'],
MONK: ['STR', 'DEX'],
};