fix(rules): apply the power attack penalty to melee touch attacks

PF1e (CRB Power Attack): "take a -1 penalty on all melee attack rolls ...
The bonus damage does not apply to touch attacks." A melee touch (kind
"touch", no range increment) is a melee attack, so _power_attack_amt now
rides its attack and confirmation rolls; the +2X/+3X damage bonus stays
gated on kind == "melee". Ranged attacks and rays are unaffected. The
test that pinned the old melee-weapon-only simplification was rewritten to
lock the corrected behavior; README and abilities.py updated.

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-09-11 23:35:07 +02:00
parent 8a8b813889
commit a2825e73cc
4 changed files with 30 additions and 11 deletions
+3 -2
View File
@@ -139,8 +139,9 @@ DODGE = AbilitySpec(
),
)
# Power Attack: active feat — declare at turn start, -X atk / +2X dmg on all
# melee attacks this turn, where X = BAB//4 + 1 (min 1). No passive modifiers;
# Power Attack: active feat — declare at turn start, -X atk on all melee
# attack rolls (melee touch included) and +2X dmg on melee WEAPON damage only
# (never touch), where X = BAB//4 + 1 (min 1). No passive modifiers;
# the engine checks for this feat and the ``power_attack`` flag on state.
POWER_ATTACK = AbilitySpec(
name="Power Attack",