Converts the targets value into a formula field so spells can change their values as they upcast. In order to support this and reduce code duplication the formula resolution logic used by max uses & duration fields was moved into its own method. All of the activated effect template data preparation was also moved into the data model at the same time.
In order to ensure these formulas resolve properly using item data for non-embedded items (Bless should show targets even when not on an actor), this modifies getRollData to always return item data even for non-embedded items.
In addition, the replaceFormulaData method has been moved from Item5e into utils to make it more generally available.
Converts the targets value into a formula field so spells can change their values as they upcast. In order to support this and reduce code duplication the formula resolution logic used by max uses & duration fields was moved into its own method. All of the activated effect template data preparation was also moved into the data model at the same time.
In order to ensure these formulas resolve properly using item data for non-embedded items (Bless should show targets even when not on an actor), this modifies
getRollData
to always return item data even for non-embedded items.In addition, the
replaceFormulaData
method has been moved fromItem5e
into utils to make it more generally available.Closes #3537