Change Log
- References to a “run” have been replaced with the term “run”.
- On healing given no longer states “or whenever you are healed”.
This is a list of every single thing in the Battle System that could trigger a proc. This should help the programming team design their architecture around the kinds of events that can trigger.
Modifiers
If any of these procs have modifiers, they should be checks implemented into the specific effect. For example:
- If an effect procs upon hitting a burning enemy, the effect will always proc on hit, but will terminate its code early if the enemy is not burning.
- If an effect procs upon gaining a debuff, the effect will always proc on status gained, but will terminate its code early if the effect gained is not a debuff.
Proc Spacing
- We don’t want every single global proc effect to trigger at the exact same time, or the player will lose track of what’s going on. They should be triggered one by one, spaced apart by a constant time interval.
- These effects are being addressed in particular because they are not a result of any battle events; their effects may as well be battle events themselves.
Proc Effect Sorting Order
Use the following instructions to sort proc effects that are triggered from the same source/event. If they are found to be identical from these instructions, leave them in the order they were found.
This order is not set in stone. Design may want to change the order while balancing, but the groups will remain the same.
- Every proc effect should be given a priority value, defaulted to 0. Positive values trigger first, and negative values trigger last.
- The following procs should trigger in order:
- Player passives
- Enemy passives
- Player items
- Enemy items
- For items, they should trigger in this order:
- Defense
- Damage
- Utility
Examples:
- A has a priority of 0, and B as a priority of 1. B goes first.
- Both have priority 0, but A is a player passive and B is a player item. A goes first.
- Both have priority 1, and both are player items, but A is a defence item and B is a damage item. A goes first.
- Both have priority 1, and both are player passives. Leave them as is.
On hit
The effect procs when another ability or effect applies damage to a unit. Generally applies to attacks, projectiles, and AOE blasts. Attacks that deal damage multiple times will proc on every single hit.
Items must consider its proc coefficient when deciding whether or not to trigger this proc, and how much damage resulting effects should do. (Specs for that coming ASAP.)
Accessible data
Procs of this type should have access to the targeted unit and the attacking unit. This is because effects may apply to either or both, depending on the effect.
On ability use
The effect procs when this unit uses an ability.
Accessible data
Procs of this type should have access to the ability’s properties, targeted unit, and caster unit. This is because, depending on the effect, some effects may require specific ability properties to be met before it’s applied to the targeted unit and/or the caster.
On hurt
The effect procs when this unit is hit. Pretty much the opposite of “on hit,” directed at the self.
On death
The effect procs when this unit’s HP reaches 0.
On kill
The effect procs when an attack, ability or effect triggered by this unit kills another unit.
On turn start
The effect procs when the unit’s team’s turn starts. Generally applies to status effects or passive buffs.
On turn end
The effect procs when the unit’s team’s turn ends. Same as above.
On cell enter
The effect procs when the unit enters a specific cell. Generally applies to cells which have a particular cell state.
On cell exit
The effect procs when the unit exits a specific cell. Opposite of above.
On battle start
The effect procs at the start of the battle, after battle initialisation but before the player’s first turn.
On battle end
The effect procs when the battle reaches a conclusion. These kinds of procs would probably only trigger when the player wins (because if they lose, the run is over anyway), but please account for either outcome anyway.
On heal
The effect procs whenever you gain health in any way, from any source. These effects may apply to you OR the target that healed you OR both (even if you are both the caster and the target).
On healing given
The effect procs whenever you apply healing to another unit. Same logic as on heal.
On shield
The effect procs whenever you gain shield in any way, from any source. Same logic as on heal.
On shield given
The effect procs whenever you apply shield to another unit. Same behaviour as on healing given. Same logic as on heal.
On status gained
The effect procs when you receive a new stack of a status effect in any way, from any source. Same logic as on heal.
On status given
The effect procs when you give a stack of a status effect to another unit. Same logic as on heal.