4

I ran into an interesting problem while trying to figure out the average time a hero would spend stunned if they were attacked continuously with a bash item or ability.

For example, if I was playing Slardar, and had a 25% chance bash for 1 second, and could attack twice a second, then what percentage of time can I expect my opponent to be bashed for? I want to know what the increments are, so that I can figure out when it's worth it to level that skill.

I came up with the following state diagram to help me through it. The states represent a half-second period after each attack.

State Diagram

Note that new stuns will refresh old ones (not stack). For example:

  ACTIVE... MISS
=ACTIVE... HIT
=STUNNED (for this round and next)... HIT
=STUNNED (for this round and next)... MISS
=RECOVERING (for this round)... HIT
=STUNNED (for this round and next)... MISS
=RECOVERING (for this round)... MISS
=ACTIVE...


Is there a formula which would fit any number of seconds, and any percent chance of stunning?

  • 5
    I'm voting to close this question as off-topic because this is a math problem wrapped in some game terms. – Elva Sep 5 '17 at 6:01
  • 2
    Knowing the damage output decrease from stunning your opponent is highly relevant for games like Dota, that implement stun-on-hit. – Addison Sep 5 '17 at 6:04
  • 11
    Theorycrafting questions like this are not off-topic... In quite a few games you need to do the math (damage, timing, etc) in order to be more than an average player. – dly Sep 5 '17 at 6:25
  • 1
    This question is more complicated than it originally seems due to bashes being pseudo-random. I'm also not sure if it's possible to bash someone during a bash. – Haibo Li Sep 5 '17 at 10:54
  • 1
    How about now @Frank? This is now a question about how the lockdown potential of Slardar, a hero in Dota, changes with attackspeed and ability levels. – Addison Sep 5 '17 at 12:19
4

Pseudo-Random

As it was commented the 25% isn't a constant in each attack but more an average of times it will proc from a bigger pool of attacks.

How does it work, the real chance to stun is 8% per attack at full level, every time it doesn't proc this chance is increased another 8.5% until stuns the target and then it resets to the base of 8%.

P(T): The chance for the skill to proc 25%

P(A): The average for the skill to proc 24.90%

C: Contant value from the Pseudo Random distribution 0.08475

Max N: The minimum number of hits that would occur until the next one is a sure proc: 12

Most Probable N: The amount of hits to get a proc: 3

Average N: The average hits until get a proc 4.02

Answer:

If you hit every 0.5 seconds and the average proc it's at the 4.02 hit then the target could be stunned every two seconds.

https://webcache.googleusercontent.com/search?q=cache:wu6BspkLHVwJ:https://dota2.gamepedia.com/Random_distribution+&cd=1&hl=es&ct=clnk&gl=ec

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.