Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
9413130
feat: Rust combat engine with full STS parity
JackSwitzer Apr 2, 2026
747d570
docs: comprehensive engine audit — 8 critical, 22 high, 9 arch issues
JackSwitzer Apr 2, 2026
076ba32
feat: engine v2 — typed entities, verb pipeline, MCTS-optimized state…
JackSwitzer Apr 4, 2026
905ca77
feat: modifier pipelines, cross-enemy AI, centralized healing
JackSwitzer Apr 4, 2026
6a07d16
feat: wire 15 stubbed relics + fix potion damage pipeline
JackSwitzer Apr 4, 2026
f908ed0
feat: interactive choice system + relic counters + card effect handlers
JackSwitzer Apr 10, 2026
7ca1ba3
fix: choice resolvers for Dual Wield, Armaments, and Exhume
JackSwitzer Apr 10, 2026
1fc6e90
fix: wire dead statuses, fix sentry stagger, call on_victory relics
JackSwitzer Apr 10, 2026
053d932
feat: add on_draw, on_discard, and on_retain hook dispatch
JackSwitzer Apr 10, 2026
4745c33
feat: fix tag mismatches + add 25 simple card effect handlers
JackSwitzer Apr 10, 2026
99c456b
Merge branch 'feat/engine-hooks' into feat/engine-tag-mismatches
JackSwitzer Apr 10, 2026
a1bb4b7
feat: per-card scaling + card generation handlers
JackSwitzer Apr 10, 2026
a4e6efb
feat: choice-based card effects + fix effective cost to respect insta…
JackSwitzer Apr 10, 2026
ff7fb85
Merge branch 'feat/engine-choice-cards' into feat/engine-complete
JackSwitzer Apr 10, 2026
1f674dd
Merge branch 'feat/engine-dead-statuses' into feat/engine-complete
JackSwitzer Apr 10, 2026
404d175
fix: resolve merge conflicts and API mismatches across PR4+PR5+PR7
JackSwitzer Apr 10, 2026
d7342e7
feat: powers, dynamic cost, innate draw, and Corpse Explosion
JackSwitzer Apr 10, 2026
b0d7767
fix: 13 audit bugs — draw pile top, Sharp Hide, Establishment, vigor …
JackSwitzer Apr 10, 2026
7409402
feat: scaffold effects module with EffectFlags bitset and dispatch fu…
JackSwitzer Apr 10, 2026
77cc602
fix: Omniscience draw pile, Perseverance/Windmill scaling, Masterful …
JackSwitzer Apr 10, 2026
132d7ac
feat: migrate 16 effect tags to EffectFlags bitset dispatch (Step 1)
JackSwitzer Apr 10, 2026
51d3d5a
feat: migrate 10 damage modifier tags to EffectFlags dispatch (Step 2)
JackSwitzer Apr 10, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .claude/scheduled_tasks.lock

This file was deleted.

624 changes: 624 additions & 0 deletions docs/m4-system-config.md

Large diffs are not rendered by default.

21 changes: 21 additions & 0 deletions docs/research/codex-adversarial-2026-04-01.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Codex Adversarial Review — 2026-04-01 (post-parity suite)

## State: 1686 passed, 0 failed, 1 ignored

## Findings (10 total: 2 critical, 6 high, 2 medium)

### Critical
1. **Power cards are inert after play** — install_power is a short allowlist. Barricade, Demon Form, Noxious Fumes, A Thousand Cuts, Infinite Blades, Well-Laid Plans, Corruption all no-ops.
2. **Double Tap, Burst, Echo Form not wired** — Java replays cards, Rust ignores them.

### High
3. **After Image ordering** — Rust fires before card effects; Java queues it after card's own actions in the action queue (subtle ordering difference).
4. **Delayed-turn tags dead** — next_turn_block, next_turn_energy, draw_next_turn, retain_hand, no_draw never consumed at turn start/end.
5. **Enemy move effects dropped** — narrow whitelist, many effects (Hex, Wounds, Constricted, debuff removal, Heart buffs, upgraded Burns, draw reduction) never consumed. Key mismatch: burn_upgrade vs burn+.
6. **Relic triggers write unused flags** — Bag of Preparation, Ring of the Snake, Pocketwatch, Damaru, Ink Bottle, Mummified Hand effects never consumed.
7. **Orange Pellets hardcoded debuff subset** — should clear ALL debuffs, not just 5.
8. **Run simulation far from Java** — no Neow, Watcher-only, ends after first boss, placeholder rewards.

### Medium
9. **Status key mismatches** — NoDraw vs "No Draw", LikeWater vs LikeWaterPower, Omega vs OmegaPower.
10. **TODO cards still approximations** — Conjure Blade, Omniscience, Wish.
41 changes: 41 additions & 0 deletions docs/research/codex-post-phase1-2026-04-01.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Codex Post-Phase-1 Review (2026-04-01)

## Core Issue
Phase 1 installed 68 handlers but many write statuses the engine never reads.
"Many new installs now write statuses that the live engine never reads."

## 15 Findings (12 high, 3 medium)

### Status keys wrong (fix immediately)
- "Tools of the Trade" → Java "Tools Of The Trade"
- "Well-Laid Plans" → Java "Retain Cards"
- "Hello World" → Java "Hello"
- "Electrodynamics" → Java "Electro"
- "Sadistic Nature" → Java "Sadistic"

### Statuses installed but never consumed by engine
- Corruption: skills should cost 0 + exhaust (engine.rs effective_cost + play_card)
- Establishment: retained cards cost -1 (engine.rs effective_cost)
- Machine Learning: extra draw per turn (engine.rs start_player_turn)
- Bullet Time: hand costs 0 + No Draw (engine.rs effective_cost + draw_cards)
- Doppelganger: next turn draw+energy (engine.rs start_player_turn)
- Wraith Form: -1 Dex per turn (engine.rs start_player_turn)
- Echo Form: replay first card (engine.rs play_card)
- Creative AI: add random Power to hand (engine.rs start_player_turn)

### Temporary effects never expire
- Rage: should clear at end of turn
- Flex (TempStrength): should remove at end of turn
- Piercing Wail (TempStrengthLoss): should restore at end of turn

### Card behavior bugs
- Ragnarok: incorrectly enters Wrath stance (Java doesn't)
- damage_random_x_times: hits all enemies once THEN random loop (should be random only)
- Conjure Blade: Expunger never reads ExpungerHits
- Electrodynamics: wrong amount, should channel Lightning + set Electro
- Heart painful_stabs: should be ongoing power, not immediate Wound

### Still approximations (medium)
- Meditate, Lesson Learned, Foreign Influence, Omniscience, Wish
- PowerId registry has non-Java IDs
- CardDef missing Java tag field (HEALING, STRIKE, etc.)
26 changes: 26 additions & 0 deletions docs/research/codex-post-phase15-2026-04-01.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Codex Post-Phase-1.5 Review (2026-04-01)

## 5 Findings (3 high, 2 medium)

### 1. HIGH: 11 powers still installed but never consumed
- Establishment, RetainCards, Loop, Electrodynamics, Magnetism, Mayhem (from install_power)
- DoppelgangerDraw, DoppelgangerEnergy, WraithForm, EchoForm, CreativeAI (from card_effects)
- Helper consumers exist in powers/buffs.rs but engine.rs never calls them

### 2. HIGH: Trigger ordering mismatches
- Devotion fires pre-draw (should be post-draw)
- Metallicize/PlatedArmor/LikeWater fire before status card damage (should be after in Java?)
- WraithForm not consumed at all (should lose Dex each turn)

### 3. MEDIUM: Raw status strings remain in peripheral files
- state.rs, potions.rs, relics/run.rs, obs.rs, enemies/*.rs still use raw strings

### 4. MEDIUM: 131 card effect tags still unhandled
- High-signal: next_turn_energy/block/draw, double_tap, burst, echo_form, creative_ai
- rampage, finisher, flechettes, genetic_algorithm, dual_wield, recycle, discovery, madness, etc.

### 5. HIGH: Damage pipeline missing generic power hooks
- deal_damage_to_enemy: misses Invincible cap, ModeShift, Angry, Curiosity, Buffer
- deal_damage_to_player: misses Thorns, Flame Barrier, Static Discharge
- Hardcoded double_damage=false, flight=false
- Offering HP loss bypasses Rupture hook
27 changes: 27 additions & 0 deletions docs/research/codex-post-phase2-2026-04-01.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Codex Post-Phase-2 Review (2026-04-01)

## 5 HIGH findings

### 1. Turn ordering mismatches
- WraithForm: Rust start-turn, Java end-turn
- Loop: Rust end-turn, Java start-turn
- CreativeAI/Magnetism: Rust post-draw, Java start-turn

### 2. 10 remaining dead statuses
- Mayhem, RetainCards (installed but no-oped)
- DrawCard, NextTurnBlock, Energized (set by card_effects, never consumed at turn start)
- DoubleTap, Burst (set by card_effects, never consumed in play_card)
- Curiosity, Invincible (helpers exist, never called)

### 3. Double Tap/Burst/Echo Form replay incomplete
- DoubleTap/Burst: statuses set but play_card never checks them
- EchoForm: only re-runs effects, Java duplicates full card from onUseCard

### 4. Enemy damage pipeline gaps
- Invincible cap not checked in deal_damage_to_enemy
- Flight per-turn reset missing
- Angry too broad (fires on poison/thorns, Java only on player attacks)

### 5. Reactive power cards never install
- Static Discharge, Flame Barrier: card tags exist but install_power has no match arm
- Curiosity: helper exists but never called from play_card
Loading