How is explosion damage calculated?

For example, if a shell hits a target 7m away from the center of impact, how much damage does that target take? Is the formula just (base damage)*(distance)/(blast radius)?

There is something wrong with your formula
Or i don’t understand it

So for example
base damage - 2500
Radius to the target from the center of blast - 1m
blast radius - 10m

2500 * 1 / 10 = 250
so if i will stay at position 1 meter from the center i take only 250 damage ?
2500 * 10 / 10 = 2500
If i will stay at position 10 meter from the center i take 2500 damage ?

3 Likes

Oh sorry, the formula I meant was (base damage)(1-(distance)/(blast radius)).
So it would be 2500
9/10 = 2250 at a 1m distance, 2500*0/10 = 0 at exactly 10m away.

Test it on Apocalypse level
Work perfect
Only thing that confuses
And take some time to figure it out
Shell doesn’t land exactly on targetPos
So it cause small error
If you rely on distanceTo( targetPos ) of shell instead of real landing position

3 Likes

Ah I see. How far off is the landing position from the targetPos?

Few examples

hero.distanceTo 6.949302306663394 landing position {x: 42.07, y: 23.66, z: 1.00}
hero.distanceTo 6.977179468168637 targetPos {x: 42.02, y: 23.64, z: 1.00}

hero.distanceTo 6.7037251853667525 landing position {x: 43.45, y: 30.49, z: 1.00}
hero.distanceTo 6.693917622678342 targetPos {x: 43.40, y: 30.48, z: 1.00}

hero.distanceTo 6.610299010906141 landing position {x: 43.49, y: 30.49, z: 1.00}
hero.distanceTo 6.599999999999996 targetPos {x: 43.44, y: 30.49, z: 1.00}
2 Likes

Pretty insignificant I guess. Thanks for running the test though