fix: attack style reset on weapon swap + ranged style highlight swap #215

Merged
sickday merged 1 commit from fix/attack-style-weapon-swap into main 2026-07-22 23:22:53 +00:00
Owner

Two combat-tab bugs:

  • Weapon swaps no longer reset the selected attack style. The fight
    mode carries over whenever the new weapon's panel offers a button
    with the same mode (Rapid stays Rapid across crossbows, aggressive
    stays aggressive across melee weapons), falling back to the first
    style only when it doesn't (e.g. a spear's controlled modes after
    swapping to a bow). Autocast and a primed special still clear.
    Unequipping the weapon now runs the same reset instead of skipping
    it entirely.

  • The style-button highlight (varp 43) is now driven by each button's
    baked CS1 equality constant extracted from the 468 cache instead of
    the button's rank in child-id order. On the axe, hammer, bow, claws
    and crossbow panels the child ids run out of visual order (top-right
    has a higher child id than bottom-left), so the rank heuristic lit
    the wrong button: selecting Rapid on a crossbow highlighted
    Longrange, and re-installing the panel snapped the highlight to the
    wrong style. The behavior table itself was already correct.

Two combat-tab bugs: - Weapon swaps no longer reset the selected attack style. The fight mode carries over whenever the new weapon's panel offers a button with the same mode (Rapid stays Rapid across crossbows, aggressive stays aggressive across melee weapons), falling back to the first style only when it doesn't (e.g. a spear's controlled modes after swapping to a bow). Autocast and a primed special still clear. Unequipping the weapon now runs the same reset instead of skipping it entirely. - The style-button highlight (varp 43) is now driven by each button's baked CS1 equality constant extracted from the 468 cache instead of the button's rank in child-id order. On the axe, hammer, bow, claws and crossbow panels the child ids run out of visual order (top-right has a higher child id than bottom-left), so the rank heuristic lit the wrong button: selecting Rapid on a crossbow highlighted Longrange, and re-installing the panel snapped the highlight to the wrong style. The behavior table itself was already correct.
fix: attack style reset on weapon swap + ranged style highlight swap
All checks were successful
ci / test (pull_request) Successful in 2m32s
a794b976ff
Two combat-tab bugs:

- Weapon swaps no longer reset the selected attack style. The fight
  mode carries over whenever the new weapon's panel offers a button
  with the same mode (Rapid stays Rapid across crossbows, aggressive
  stays aggressive across melee weapons), falling back to the first
  style only when it doesn't (e.g. a spear's controlled modes after
  swapping to a bow). Autocast and a primed special still clear.
  Unequipping the weapon now runs the same reset instead of skipping
  it entirely.

- The style-button highlight (varp 43) is now driven by each button's
  baked CS1 equality constant extracted from the 468 cache instead of
  the button's rank in child-id order. On the axe, hammer, bow, claws
  and crossbow panels the child ids run out of visual order (top-right
  has a higher child id than bottom-left), so the rank heuristic lit
  the wrong button: selecting Rapid on a crossbow highlighted
  Longrange, and re-installing the panel snapped the highlight to the
  wrong style. The behavior table itself was already correct.
sickday force-pushed fix/attack-style-weapon-swap from a794b976ff
All checks were successful
ci / test (pull_request) Successful in 2m32s
to 9e5c7ede6f
All checks were successful
ci / test (pull_request) Successful in 2m32s
2026-07-22 23:19:22 +00:00
Compare
Sign in to join this conversation.
No description provided.