mantimon-tcg/backend
Cal Corum 092f493cc8 Add stat modifiers and attack cost overrides to CardInstance
Support card effects that modify Pokemon stats:
- hp_modifier: Additive HP change (e.g., +20 from Giant Cape tool)
- retreat_cost_modifier: Additive retreat cost change (e.g., -99 for Float Stone)
- damage_modifier: Additive damage change for attacks
- attack_cost_overrides: dict[int, list[EnergyType]] for per-attack cost changes

Added helper methods:
- effective_hp(base_hp) - returns max(1, base_hp + hp_modifier)
- effective_retreat_cost(base_cost) - returns max(0, base_cost + modifier)
- effective_attack_cost(attack_index, base_cost) - returns override or base

Updated is_knocked_out() and remaining_hp() to use effective HP.

Also updated PROJECT_PLAN.json:
- Marked HIGH-003, TEST-006, HIGH-004 as completed (Week 2 complete)
- Updated test counts and notes to reflect stat modifier coverage

289 tests passing.
2026-01-24 23:52:20 -06:00
..
app Add stat modifiers and attack cost overrides to CardInstance 2026-01-24 23:52:20 -06:00
tests Add stat modifiers and attack cost overrides to CardInstance 2026-01-24 23:52:20 -06:00
.gitignore Add backend foundation with uv, Black, and pre-commit hooks 2026-01-24 00:12:33 -06:00
.python-version Add backend foundation with uv, Black, and pre-commit hooks 2026-01-24 00:12:33 -06:00
PROJECT_PLAN.json Add stat modifiers and attack cost overrides to CardInstance 2026-01-24 23:52:20 -06:00
pyproject.toml Add backend foundation with uv, Black, and pre-commit hooks 2026-01-24 00:12:33 -06:00
uv.lock Add backend foundation with uv, Black, and pre-commit hooks 2026-01-24 00:12:33 -06:00