Active Effects allow you to change actor values dynamically depending on what active effects are enabled. Want to change an attribute whenever some cyberware is equipped? That's how to do it.
It's strongly recommended to use the Autocomplete Inline Properties module. Doing so will allow to directly see data fields and their corresponding values and also greatly help with traversal of the data structures
Generally, you can add an effect to an actor by either
- manually creating it on the actor, either as passive or temporary or
- creating an item with an active effect, set to transfer to the actor, and giving it to an actor, adding the effect in the process.
What modes to use?
The shadowrun5e system uses a extended version of the active effects as they are're used in other systems like DnD5e. For most use cases these modes should be used:
- Modify (Whenever you modify a value that's on your sheet)
- Add (Whenever you want to manually hard add something, might conflict with the system value calculation on some fields (.value))
- Overwrite (Whenever you don't like the systems calculation)
Modify
This custom mode of the system allows to either add a modifier to a value or add directly to it if a modifier can't be applied.
If the value choosen contains a .mod
field the system will automatically add you're effect to the calculation overview that's shown when hovering over some values (try attributes).
It doesn't matter if a general value as a whole or any of it's fields are choosen; the modify mode will always behave the same and not override whatever field is defined.
Should you provide a value without a .mod
field the modify mode it will fall back to using the add mode.
example active effect attribute keys:
data.attributes.body
data.attributes.body.value
(or.base
,.mod
or.temp
)data.skills.active.arcana
data.limits.physical
Override
The override mode has been heavily modified from other systems and supports the same value type as the modify mode (must contain a mod field). The override mode will keep the targeted value as is but override it's calculation by what's defined as it's effect value. It will also be visible in the calculation overview of a value, where it will show the actual total crossed out and the override value as the new total. No values are changed by this. Should you define multiple override effects on the same value, only the last on applied will take effect.
Other Modes
The default modes FoundryVTT provides for it's active effects are kept as is. For explanation on how they work, others on YouTube and other plattforms have provided great tutorials.
Actor Data Structure
If you can't find what you're looking for, check if a global modifier for it exists. Some values contain temp fields, that can be modified by active effects.
data.attributes.<attributeName>
contains all attributes.data.skills.active.<skillName>
contains all active skills. Custom skills will be shown with a random ID. To see the actual custom name of the skill traverse into it and read it's name field.data.limits.<limitName>
contains all limits.data.modifiers
contains all global modifiers and can be directly modified.
Success Test Pools
Currently SR5 v0.14.1 only skill pools can be modified, while specific test categories (social tests, matrix tests, ...) can't.