What I do is opening the lua file in /data/timed_effects and check every DoT effects, and classify them on their on_merge function.
Type 1 -- stacking with the following function:
Code: Select all
local olddam = old_eff.power * old_eff.dur local newdam = new_eff.power * new_eff.dur local dur = math.ceil((old_eff.dur + new_eff.dur) / 2) old_eff.dur = dur old_eff.power = (olddam + newdam) / dur return old_eff
Poison, Stoning Poison, Deadly Poison, Blight Poison *the final damage can't be bigger than 5* damage of the new effect
Attenuate *the regeneration can also merge!
Reality Smearing *actually a DoT to paradox
Dark Whispers *the final power reduction is the sum of the ones of the old and the new effect
Type 2 -- stacking with the following function:
Code: Select all
local olddam = old_eff.dam * old_eff.dur local newdam = new_eff.dam * new_eff.dur new_eff.dam = (olddam + newdam) / new_eff.dur return new_eff
Type 3 -- the final duration is the longer of the old effect and the new effect, while the final damage is just the one of the new effect.
all kinds of other poisons, except Leeching Poison and Vulnerability Poison, and their blight version (Spydric Poison, Insidious Poison/Blight, Crippling Poison/Blight, Numbing Poison/Blight, Metal Poisoning)
Type 4 -- the final duration is the one of the new effect, and the final damage per turn is the sum of the ones of the old and the new effect.
but TBH can you ever make this merge happen
Type 5 -- the final duration is the longer of the old effect and the new effect, and the final damage per turn is the sum of the ones of the old and the new effect.
Type 6 -- no stacking at all, the old effect is just replaced by the new effect.
Constricted *actually a DoT to air
banes (Bane of Blindness, Bane of Confusion)
Curse of Death
Manaworm *actually a DoT to mana
all diseases except Viral Injection (Rotting Disease, Decrepitude Disease, Weakness Disease, Epidemic, Worm Rot, Ghoul Rot, Crippling Disease)
Death in a Dream
Touch of Death
Only Ashes Left
Black Blood Bleeding
Total Collapse *but the damage grows higher each turn by itself