Skip to content

engine: implement 6 more abilities (Leaf Guard, Liquid Ooze, Unaware, Rock Head, Serene Grace, Sand Force follow-on)#89

Merged
shaumik merged 4 commits into
mainfrom
feat/abilities-tierA
Jun 26, 2026
Merged

engine: implement 6 more abilities (Leaf Guard, Liquid Ooze, Unaware, Rock Head, Serene Grace, Sand Force follow-on)#89
shaumik merged 4 commits into
mainfrom
feat/abilities-tierA

Conversation

@shaumik

@shaumik shaumik commented Jun 25, 2026

Copy link
Copy Markdown
Owner

Follows #88. Continues the ability backlog with Tier A entries that reuse or minimally extend existing hooks, bringing coverage to 68/107. Each batch is one commit.

Batches

Batch Abilities Integration
4 Leaf Guard, Liquid Ooze new BlocksStatusState guard in inflictStatus; DrainBackfires flag in the drain path
5 Unaware IgnoresOpponentStages flag zeros the foe's stages in offensiveDefensiveStats (both attacking and defending)
6 Rock Head, Serene Grace BlocksRecoil flag in the recoil branch; SecondaryChanceMult (×2, clamped 100%) in the secondary-roll loop

Tests

Each ability has behavioral coverage in abilities_test.go (Leaf Guard sun gating, Liquid Ooze drain backfire, Unaware both directions, Rock Head recoil negation, Serene Grace multiplier + clamp). Full engine suite green.

Scope

All changes confined to abilities.go, effects.go, damage.go, and abilities_test.go.

Shaumik Mondal added 4 commits June 24, 2026 22:51
Leaf Guard refuses every major status while the sun is up, via a new
state-aware BlocksStatusState guard consulted in inflictStatus. Liquid Ooze
turns a drain against its holder into damage on the drainer instead of a
heal, gated by a new DrainBackfires flag in the effects drain path.
Unaware blanks the opponent's stat stages in the damage formula: when its
holder attacks, the defender's defensive boosts are ignored; when it defends,
the attacker's offensive boosts are ignored. Unlike IgnoreDefensive (which
only clamps positive defensive stages), Unaware zeros stages in both
directions, via a new IgnoresOpponentStages flag read in
offensiveDefensiveStats.
Rock Head cancels the holder's own move recoil (narrower than Magic Guard's
blanket indirect-damage immunity), via a BlocksRecoil flag checked in the
recoil branch. Serene Grace doubles the holder's secondary-effect chances on
damaging moves (clamped at 100%), via a SecondaryChanceMult read in the
secondary-roll loop.
Re-align struct fields and registry entries after the batch 4-6 additions;
no behavior change. Fixes the Format CI step.
@shaumik shaumik force-pushed the feat/abilities-tierA branch from c9fe67a to db80a6e Compare June 25, 2026 05:52
@shaumik shaumik merged commit 21d8540 into main Jun 26, 2026
1 check passed
@shaumik shaumik deleted the feat/abilities-tierA branch June 26, 2026 03:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant