merge of the DoTs

Any discussions regarding the spoilers present in ToME 4.x.x should be restricted to this forum

Moderator: Moderator

Post Reply
Message
Author
helminthauge
Thalore
Posts: 177
Joined: Sat Sep 29, 2018 3:43 am

merge of the DoTs

#1 Post by helminthauge »

I've seen people boasting DoTs, saying that they can "stack". So here we see how the "stack" really works.
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
what this does is basically calculating the total damage of the old effect and the new effect, and then spread them evenly to the average of the duration of the old effect and the new effect, rounding up.

Bleeding
Poison, Stoning Poison, Deadly Poison, Blight Poison *the final damage can't be bigger than 5* damage of the new effect
Burning
Wasting
Lightburn
Attenuate *the regeneration can also merge!
Reality Smearing *actually a DoT to paradox
Fiery Grasp
Burning Plague
Heartrended
Voidburn
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
what this does is basically calculating the total damage of the old effect and the new effect, and then spread them evenly to the duration of the new effect.

Damage Smearing

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)
Maim
Viral Injection

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.

Cauterize
but TBH can you ever make this merge happen :roll:

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.

Entropic Wasting

Type 6 -- no stacking at all, the old effect is just replaced by the new effect.

Deep Wound
Burning Shock
Constricted *actually a DoT to air
Crushing Hold
Strangle Hold
Imploding
Thorn Grab
Ravage
Bear Trap
Stone Vine
Leeching Poison
Agony
Void Echoes
Waking Nightmare
Nightmare
Restless Night
banes (Bane of Blindness, Bane of Confusion)
Curse of Death
Acid Splash
Hurricane
Manaworm *actually a DoT to mana
Temporal Destabilization
Impending Doom
all diseases except Viral Injection (Rotting Disease, Decrepitude Disease, Weakness Disease, Epidemic, Worm Rot, Ghoul Rot, Crippling Disease)
Vulnerability Poison
Death in a Dream
Touch of Death
Cleansing flames
Blazing Rebirth
Demonic Cut
Only Ashes Left
Larvae Infestation
Explosive Saw
Bloodstar
Psy Worm
Black Blood Bleeding
Tentacle Construction
Dissolved Face
Entropic Gift
Total Collapse *but the damage grows higher each turn by itself
Glass Splinters

helminthauge
Thalore
Posts: 177
Joined: Sat Sep 29, 2018 3:43 am

Re: merge of the DoTs

#2 Post by helminthauge »

other interesting facts:
1) The damage of the DoT in tooltip is before the damage type bonus of the source applying it.
i.e. Assume that you have no defense at all (no resistance, no AM shield, no flat damage reduction, no whatever), and you are hit by a Flame from an archmage rare. You get a burning effect that deals 20 fire damage per turn in tooltip and that archmage rare have a +50% fire damage bonus, you're actually taking 30 fire damage per turn.

2) A:what if the source applying the DoTs changes its corresponding damage type bonus and/or resistance penetration during the effect?
Q:the rest of the damages are increased by the new damage type bonus and penetrate resistance with the new resistance penetration.

3) A:what if the target is hit by a type 1 DoT from multiple sources with different corresponding damage type bonus and/or resistance penetration?
Q:the DoT uses the damage type bonus and resistance penetration of the source that first applies this DoT. I think it's the same for type 2 and type 4 DoTs.
i.e. You're a sawbutcher, and you're hitting a mob with very high physical resistance already bleeding from a Bone Spear from a corruptor enemy (who has no physical damage bonus and penetration), then your bleeding damage is going to suck because it also has no damage bonus and penetration.

Post Reply