refactor(modifiers): use baseAttr for preset source mapping
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
parent
c74a1fca00
commit
3d49cd2792
4 changed files with 21 additions and 7 deletions
|
|
@ -64,3 +64,8 @@ Probable file: add test to `solo-smoke.spec.ts` (T2 added it as the canary) or e
|
|||
|
||||
- Implemented the adapter path in `modifiers/registry.ts`: stored descriptors now wrap typed `apply/describe` in `unknown`-accepting closures at registration time.
|
||||
- Result: removed the `descriptor as unknown as ModifierDescriptor` storage cast; `schema.ts` parse return also reduced from double-cast to `as ModifierProfile`.
|
||||
|
||||
## [2026-04-19 14:01] Task: commit-3 preset source attribution
|
||||
|
||||
- Added optional `baseAttr?: ChessAttrKey` to `ModifierDescriptor` and set `hp-bonus` to `baseAttr: "Hp"`.
|
||||
- Removed hardcoded `HpBonus`/`RangeBonus` aliasing from `getModifierSource`; source matching now uses `descriptor.baseAttr ?? descriptor.attrName` directly.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue