Add masterwork rework, arena combat log, Death's Reprieve fix, and wordle improvements

Adventure — Masterwork Rework:
- Expand from 3 generic items to 15 tiered masterwork items across
  mining (weapon), fishing (armor), and foraging (boots) with per-tier
  drop rates (5%/4%/3%/2%/1.5%) and location gating
- Skill-specific cross-skill bonuses replace flat masterwork check
- Auto-equip if better, silent discard for duplicates, inventory for rest
- Add !adventure equip command for manual masterwork equipping
- Tiered room announcements: T1-2 DM only, T3 quiet, T4-5 full
- First-drop detection with special message
- Character sheet shows /⚔️ markers for masterwork/arena gear
- Sell protection for special gear in shop

Adventure — Arena Combat Log:
- Turn-based Dragon Quest style narrative for arena fights
- Outcome-first design: roll determines win/loss, log assembled backward
- No-repeat flavor text via actionPicker with per-pool tracking
- 60 participation XP on arena loss

Adventure — Death's Reprieve Fix:
- All equipment set to 1 condition instead of death-level degradation

Wordle:
- Refactored word sourcing and expanded fallback word list
- Simplified Wordnik integration

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
prosolis
2026-03-29 16:24:59 -07:00
parent 31a1d00236
commit 0a1359de46
19 changed files with 2427 additions and 289 deletions

View File

@@ -64,6 +64,15 @@ func runMigrations(d *sql.DB) error {
// exists in SQLite (we just swallow "duplicate column name" errors).
columnMigrations := []string{
`ALTER TABLE adventure_characters ADD COLUMN holiday_action_taken INTEGER NOT NULL DEFAULT 0`,
`ALTER TABLE wordle_puzzles ADD COLUMN category TEXT NOT NULL DEFAULT ''`,
`ALTER TABLE adventure_equipment ADD COLUMN arena_tier INTEGER NOT NULL DEFAULT 0`,
`ALTER TABLE adventure_equipment ADD COLUMN arena_set TEXT NOT NULL DEFAULT ''`,
`ALTER TABLE adventure_equipment ADD COLUMN masterwork INTEGER NOT NULL DEFAULT 0`,
`ALTER TABLE adventure_characters ADD COLUMN death_reprieve_last DATETIME`,
`ALTER TABLE adventure_equipment ADD COLUMN skill_source TEXT NOT NULL DEFAULT ''`,
`ALTER TABLE adventure_characters ADD COLUMN masterwork_drops_received INTEGER NOT NULL DEFAULT 0`,
`ALTER TABLE adventure_inventory ADD COLUMN slot TEXT NOT NULL DEFAULT ''`,
`ALTER TABLE adventure_inventory ADD COLUMN skill_source TEXT NOT NULL DEFAULT ''`,
}
for _, stmt := range columnMigrations {
if _, err := d.Exec(stmt); err != nil {
@@ -803,6 +812,7 @@ CREATE TABLE IF NOT EXISTS wordle_puzzles (
room_id TEXT NOT NULL,
answer TEXT NOT NULL,
word_length INTEGER NOT NULL,
category TEXT NOT NULL DEFAULT '',
solved INTEGER NOT NULL DEFAULT 0,
guess_count INTEGER NOT NULL DEFAULT 0,
started_at DATETIME NOT NULL,
@@ -843,16 +853,22 @@ CREATE TABLE IF NOT EXISTS adventure_characters (
last_action_date TEXT NOT NULL DEFAULT '',
grudge_location TEXT NOT NULL DEFAULT '',
created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
last_active_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP
last_active_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
death_reprieve_last DATETIME,
masterwork_drops_received INTEGER NOT NULL DEFAULT 0
);
CREATE TABLE IF NOT EXISTS adventure_equipment (
user_id TEXT NOT NULL,
slot TEXT NOT NULL,
tier INTEGER NOT NULL DEFAULT 0,
condition INTEGER NOT NULL DEFAULT 100,
name TEXT NOT NULL,
user_id TEXT NOT NULL,
slot TEXT NOT NULL,
tier INTEGER NOT NULL DEFAULT 0,
condition INTEGER NOT NULL DEFAULT 100,
name TEXT NOT NULL,
actions_used INTEGER NOT NULL DEFAULT 0,
arena_tier INTEGER NOT NULL DEFAULT 0,
arena_set TEXT NOT NULL DEFAULT '',
masterwork INTEGER NOT NULL DEFAULT 0,
skill_source TEXT NOT NULL DEFAULT '',
PRIMARY KEY (user_id, slot)
);
@@ -862,7 +878,9 @@ CREATE TABLE IF NOT EXISTS adventure_inventory (
name TEXT NOT NULL,
item_type TEXT NOT NULL,
tier INTEGER NOT NULL,
value INTEGER NOT NULL
value INTEGER NOT NULL,
slot TEXT NOT NULL DEFAULT '',
skill_source TEXT NOT NULL DEFAULT ''
);
CREATE INDEX IF NOT EXISTS idx_adv_inv_user ON adventure_inventory(user_id);