|
From: Vest <no...@gi...> - 2026-08-15 11:21:47
|
Branch: refs/heads/master Home: https://github.com/PCGen/pcgen Commit: b3b8b08f2c90036bb61d061711dca38c7bafe1c0 https://github.com/PCGen/pcgen/commit/b3b8b08f2c90036bb61d061711dca38c7bafe1c0 Author: Vest <Ve...@us...> Date: 2026-08-15 (Sat, 15 Aug 2026) Changed paths: M code/src/java/pcgen/core/term/PCCasterLevelClassTermEvaluator.java M code/src/java/pcgen/core/term/PCCasterLevelTotalTermEvaluator.java M code/src/slowtest/pcgen/core/PlayerCharacterTest.java Log Message: ----------- fix: honor BONUS:PCLEVEL|TYPE in caster level evaluators (#7697) * test: reproduce BONUS:PCLEVEL|TYPE.Arcane ignored by caster level BONUS:PCLEVEL|TYPE.Arcane / TYPE.Divine (the "+1 Arcane/Divine Caster Level" GM Awards from DATA-3818) raise spells-known/per-day via SpellSupportForPCClass, but the caster-level term evaluators only query PCLEVEL|<classKey>, never PCLEVEL|TYPE.<spellType>. So the awarded caster level never actually changes on the sheet. Add a failing slowtest driving PCCasterLevelClassTermEvaluator with a fixed-CASTERLEVEL Arcane class: baseline caster level is 3, and BONUS:PCLEVEL|TYPE.Arcane|1 should raise it to 4 but currently does not. * fix: honor BONUS:PCLEVEL|TYPE in caster level evaluators The caster-level term evaluators computed the PCLEVEL bonus only from PCLEVEL|<classKey>, so BONUS:PCLEVEL|TYPE.Arcane / TYPE.Divine (the "+1 Arcane/Divine Caster Level" GM Awards) never affected caster level, even though SpellSupportForPCClass already honors PCLEVEL|TYPE.<type> for spells known and per-day. The caster-level path has never queried the TYPE target (confirmed back to 6.08.00RC4), so the award raised spell slots but silently left the caster level unchanged. Add a PCLEVEL|TYPE.<spellType> lookup alongside the existing class-key lookup in PCCasterLevelClassTermEvaluator and PCCasterLevelTotalTerm- Evaluator, mirroring SpellSupportForPCClass. In the total evaluator the bonus is summed per class using that class's own spell type, so a mixed arcane/divine caster gets each award applied only to the matching classes. Generic across all spell types, not just Arcane/Divine. Purely additive: no test character carries a PCLEVEL|TYPE ability, so all csheet fixtures are unchanged. * test: BONUS:CASTERLEVEL vs PCLEVEL TYPE caster-level contract Encode the documented distinction (globalfilesbonus.html): CASTERLEVEL|TYPE.<type> raises the caster-level number only, while PCLEVEL|TYPE.<type> raises the effective spellcasting level -- both caster level and spell progression. The shipped '+1 Arcane Caster Level' GM Award uses PCLEVEL, so the caster-level evaluators must honor it; a caster-level-only award should instead use CASTERLEVEL. To unsubscribe from these emails, change your notification settings at https://github.com/PCGen/pcgen/settings/notifications |