Fix constants fidelity: add FORMS.INSTANT_DECAY (bit D), rename RIST_L to WRIST_L - #16
Merged
Merged
Conversation
…L to WRIST_L FORMS skipped bit 8 (ROM's FORM_INSTANT_DECAY in merc.h), so a mob with that form bit parsed but rendered unnamed. enum.auto() members are unaffected: UNUSED1 stays at 32 (next power of two above OTHER=16). WEAR_LOCATIONS.RIST_L was a typo for WRIST_L; the correct name is now canonical with RIST_L kept as a deprecated alias for any external importers. Fixes #9 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01F8kWxXQUY73XMXyeUYhkLd
ctoth
force-pushed
the
fix/constants-fidelity-issue-9
branch
from
July 27, 2026 06:14
ee4102b to
323f5b1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #9.
Two fidelity fixes in
area_reader/constants.py:FORMS.INSTANT_DECAYadded (BITFLAGS['D']= 8), matching ROM'sFORM_INSTANT_DECAYin merc.h. Previously the enum jumped fromMAGICAL(4) toOTHER(16), so bit 8 parsed but rendered unnamed. Theenum.auto()members are unaffected:UNUSED1was and remains 32 (next power of two aboveOTHER), verified at runtime.WEAR_LOCATIONS.WRIST_Lis now the canonical name for 14; the misspelledRIST_Lis kept as a deprecated alias so any external importers keep working.RIST_Lhad no other references inside this repo.Verification (commands run locally):
repr(FORMS(8))→<FORMS.INSTANT_DECAY: 8>;FORMS(12)→<FORMS.MAGICAL|INSTANT_DECAY: 12>WEAR_LOCATIONS(14) is WEAR_LOCATIONS.WRIST_L→True;WEAR_LOCATIONS.RIST_L is WEAR_LOCATIONS.WRIST_L→True944 passed in 85.94s(942 existing + 2 new regression tests intest_area_reader.py)🤖 Generated with Claude Code
https://claude.ai/code/session_01F8kWxXQUY73XMXyeUYhkLd