I
I
Iq512020-06-12 12:41:51
Mathematics
Iq51, 2020-06-12 12:41:51

How to change the damage per second formula?

There is a fighter who has a regular punch.
Hit stats : Base Damage Damage , Crit Chance CritChance , CritMultiplier and AttackSpeed ​​.
Damage per second formula:

CritDamage = Damage * CritChance * CritMultiplier
NormalDamage = Damage * (1 - CritChance )
DPS = (NormalDamage + CritDamage) * AttackSpeed

​​Now every N seconds, instead of a normal hit, a new super hit occurs, which increases damage by SuperDamageMultiplier. A super hit can be a critical hit like a normal hit.

How to add a super hit to the DPS formula?

Update
With these data:
Damage = 100
CritChance = 0.3
CritMultiplier = 2
AttackSpeed ​​= 5

SuperDamageMultiplier = 10
N = 3

Average DPS in experiments 1000

Answer the question

In order to leave comments, you need to log in

3 answer(s)
R
Rsa97, 2020-06-12
@Iq51

One hit in N seconds is replaced from normal to super. We get:

DPS * N = (NormalDamage + CritDamage) * AttackSpeed * N
        - (NormalDamage + CritDamage)
        + (NormalDamage + CritDamage) * SuperDamageMultiplier
= (NormalDamage + CritDamage) * (AttackSpeed * N - 1 + SuperDamageMultiplier)

DPS = (NormalDamage + CritDamage) * (AttackSpeed + (SuperDamageMultiplier - 1) / N)

R
rPman, 2020-06-12
@rPman

+Normal Damage*SuperDamageMultiplier/N
if super damage can be for crit, add it separately

G
Grigory Boev, 2020-06-12
@ProgrammerForever

DPS2 = ((NormalDamage + CritDamage) * AttackSpeed) * SuperDamageMultiplier / N

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question