ModiBuff icon indicating copy to clipboard operation
ModiBuff copied to clipboard

GenId modifier stacking (Unit-tied unique stacking)

Open Chillu1 opened this issue 2 years ago • 0 comments

Description Currently, instance stackable modifiers are always stacked when added, no matter what. It would be nice to have stackable modifiers based on who is the source of the modifier. Meaning that a single Unit can only apply one instance of the modifier, but if another Unit applies the same modifier type, it will be another instance. With its own independent refresh, stack, etc.

Example: Two Units have a modifier named "DamageOverTime", Unit 1 applies it, then Unit 2 applies it. The target Unit now has two unique instances of that modifier, ticking together, if Unit 1 applies it again, the modifier will be refreshed, stacked, etc. But the 2nd instance applied by Unit 2

Implementation Only ModifierController will need to have extra logic, by checking if the modifier exist and if they're instance stackable, and instance genId stackable or not.

Issues For this to work, a GenId needs to be fed into ModifierController.Add, and currently we don't have access to the GenId a lot of the time, so it would either need a new id system based on casters, or some refactoring.

Chillu1 avatar Sep 30 '23 10:09 Chillu1