Accepted
Features need to be able to grant known spells to creatures (e.g., "You know the dancing lights cantrip"). We need a way to represent these features and look up the spells they grant.
We implemented SpellcastingFeature which holds a list of ISpells and adds them to the creature's ISpellCaster when applied.
We updated ISpellCaster to include UnlearnSpell to support feature removal.
We updated FeatureFactory to allow injecting an ISpellRepository and to parse spell grants from feature descriptions using regex.
FeatureFactorynow has a dependency onISpellRepository(via static setter).ISpellCasterinterface has changed (breaking change).- Creatures can now dynamically learn spells from features.