foundryvtt / pf2e

A community contributed game system for Pathfinder Second Edition.
https://foundryvtt.com/packages/pf2e
Apache License 2.0
420 stars 349 forks source link

Flexible Spells Not Removed from Collection when Deleted #2138

Closed cswendrowski closed 2 years ago

cswendrowski commented 2 years ago

In GitLab by @Nudist on Mar 11, 2022, 02:36

For flexible spell casters, if a spell has been added to a collection by checking the appropriate box and then that spell is deleted without first unchecking that box, the collection retains the spell in its count even though the spell is otherwise removed from the spellcasting entry. This causes the collection count to be inflated. For instance, adding Animal Form to a 3rd level primal flexible caster, checking the box so the character now has (1/4) noted in their collection, and then deleting Animal Form from the spellcasting entry will remove all displayed instances of the spell but will maintain the (1/4) collection count; the associated spell id is retained in the signatureSpells array for that spellcasting entry.

Currently this can be corrected by exporting the character data, finding the nested JSON object for the spellcastingEntry, and removing the ids from the array in the value entry under the signatureSpells key (e.g. changing it to an empty array in the above example). However, ideally when a spell in the collection is deleted, the updated id in the singatureSpells entry will automatically be deleted as well.

cswendrowski commented 2 years ago

In GitLab by @stwlam on Mar 20, 2022, 22:34

mentioned in commit 222bcef79f99c722f5b02a3c70053389acb52ae8