WIP: in-flight combat/expedition/flavor changes

Bundle of uncommitted working-tree edits across combat engine, expedition
cycle, flavor pools, and TwinBee/zone narration. Includes new files:
combat_debug.go, dnd_boss_consumables.go, dnd_dex_floor.go, plus
CHANGES_24H.md and REBALANCE_NOTES.md scratch notes.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
prosolis
2026-05-12 21:59:19 -07:00
parent 2b86f3df16
commit 4e412219f3
49 changed files with 1381 additions and 444 deletions

View File

@@ -294,11 +294,16 @@ func TestSetupStatus_NoStubOnFirstSetup(t *testing.T) {
}
}
func TestApplyDnDHPScaling_NeverExceedsOriginalMax(t *testing.T) {
stats := CombatStats{MaxHP: 100}
c := &DnDCharacter{HPMax: 50, HPCurrent: 100} // pathological: 200% — shouldn't happen but be safe
func TestApplyDnDHPScaling_NeverExceedsCombatMax(t *testing.T) {
// Pathological: hp_current somehow above hp_max — early-return path
// (full HP) leaves MaxHP unchanged and StartHP unset.
stats := CombatStats{MaxHP: 100, HPBonus: 50}
c := &DnDCharacter{HPMax: 50, HPCurrent: 100}
applyDnDHPScaling(&stats, c)
if stats.MaxHP > 100 {
t.Errorf("clamp failed: MaxHP scaled to %d, original was 100", stats.MaxHP)
if stats.MaxHP != 100 {
t.Errorf("MaxHP clobbered: %d, want unchanged 100", stats.MaxHP)
}
if stats.StartHP > stats.MaxHP {
t.Errorf("StartHP=%d exceeds MaxHP=%d", stats.StartHP, stats.MaxHP)
}
}