• Dear Guest,

    You're browsing our forum as a Guest meaning you can only see a portion of the forum in read-only mode.
    To view all forum nodes and be able to create threads/posts please register or log-in with your existing account.

    TwinStar team

Warlock Feo's Corner of Reflexion: Hit or Crit?

Thanks Hagson, I'll reconsider my simulation and rework it until it's fine. Then we will see if your formula fits with the test results or not :)
 
Hit doesn't matter, because a resisted shadowbolt can still "crit", applying the debuff.
This is not true for hit resisted spells. It only applies to resists by resistance. Hit does matter, resistance does not.

...Well not for the actual spell, for the binary debuff it does of course.

Not sure what that addon does and such, but seeing that the resist message is white really makes me wonder...
If the debuff even applies with "missed" spells, then this is incorrect.
 
So I've reconsidered the core ideas of how my isb uptime should work. I am still assuming a simulation of 1.000.000 casts with n warlocks, h percent hit and c percent crit.
The bold italics stuff below will be turned into code.

So basically we start with x = 1 and do a while loop:
x =1
while (x <= 1000000) {


Now comes the first cast sequence for n warlocks:
y = 1
while (y <= n) {

Here each warlock casts once then the next cast sequence for all n warlocks will start.
What I think should happen within this block, is described in the numbers 1-5 below.

increase y by 1
}



increase x by 1
}


------------------------------------------------

1. The debuff lasts 12 seconds. 12/2,5 cast time = 4,8. That means we can do 4 (4*2,5s cast time=10s) casts that reach the target within the 12 seconds.
n warlocks can do n*4 casts within the 12 seconds. If the number of casts = n*4, it means every lock has cast 4 times and the debuff is gone due to the time limit.

if (casts = 4*number of warlocks casting) -> debuff = 0

2. If the SB hits or not does not matter, because it was one out of the 4 casts which can effectively reach the target within the 12,5s.
after every cast -> casts +1

3. When the debuff is there, it mean it's up, so the uptime increases by 1
if (debuff > 0) uptime +1

4. If a shadow bolt hits the target, one debuff charge will be taken away.
if (random(1,100) <= hit) -> debuff -1

5. Since the debuff seems to get a chance to apply, regardless if the shadow bolt hits or not, each cast there will be a check for the debuff to apply (charges will be set to 4). Also the number of casts will be set to 0.
if (random(1,100) <= crit) {
if (random(1,100) <= hit) -> debuffs = 4, casts = 0
}


------------------------------------------------

So basically these are my thoughts for the simulation. Do you have any ideas what I could add or if I have forgot something?
 
So what does your code give you?

Updated my fiddle to account for the debuff being resisted: http://jsfiddle.net/turinpt/rgfdxyr4/

The uptime formula should then be:
(1 - (1 - crit * hit * hit)^4)

Crit: 15
Hit: 83
Simulated: 0.3540343
Formula: 0.3535709

Crit: 30
Hit: 95
Simulated: 0.7170835
Formula: 0.71718284

Crit: 5
Hit: 99
Simulated: 0.1818933
Formula: 0.18207603

Close enough for me.
 
Here are my results comparing the Hagson equation with my simulation results. Please note that I did check if the debuff gets resisted or not (from hit) after a shadow bolt crit. Furthermore the test results only match the Hagson formula if there are two or more warlocks casting. For one warlock the simulation and the hagson formula are roughly 9% different.


Test results:

https://docs.google.com/spreadsheets/d/1Lk2YLt59VBefZKVB7-_5gyHor1eANGY0tBmVJGitN0k/edit?usp=sharing



TLDR:
I think 0,985*(1-(1-crit)^4) is a little more accurate than (1-(1-crit)^4).

- - - Updated - - -

@GuybrushT Hagson posted evidence that the SB doesn't need to hit in order to apply the debuff. But applying the debuff can be resisted if I didn't get it wrong.
 
@GuybrushT Hagson posted evidence that the SB doesn't need to hit in order to apply the debuff. But applying the debuff can be resisted if I didn't get it wrong.

Evidence that got disproven in the post below, that was a full partial resist that crit, not a miss.
Full partial resists are pratically non existent in raids so we don't have to worry about them.

0,985*(1-(1-crit)^4) just seems like you're just multiplying it by a random value in order to get the results you want.

Hard to tell the accuracy of your simulations unless you post the full working code, have you compared it to mine?
 
Well, Hagson say's it was a miss, you say it was a full resist. To me it doesn't really matter who is right, both can be simulated, but maybe you two should agree on which approach on the issue is right.
Please feel free to take a look at the spreadsheet in my last post, it contains the simulation results. The 0.985 is just a factor I've got through testing different factors. It's there to bring the results of Hagson's equation nearer to the testing results.

This is my code, reconsidering that it was missed and not resisted and presuming that you can only cast 4 shadow bolts within the 12 seconds:
http://pastebin.com/Duh3TQM4
 
Well, Hagson say's it was a miss, you say it was a full resist. To me it doesn't really matter who is right, both can be simulated, but maybe you two should agree on which approach on the issue is right.
Please feel free to take a look at the spreadsheet in my last post, it contains the simulation results. The 0.985 is just a factor I've got through testing different factors. It's there to bring the results of Hagson's equation nearer to the testing results.

This is my code, reconsidering that it was missed and not resisted and presuming that you can only cast 4 shadow bolts within the 12 seconds:
http://pastebin.com/Duh3TQM4

Hit being applied first is a pretty well established mechanic, I don't think anyone other than Hagson thinks otherwise:

spell crit makes absolutely no difference to hit chance. All spells, regardless of whether they are treated as binary or not, roll hit and crit separately. Conceptually, the game rolls for your hit chance first, and if the spell hits you have a separate roll for whether it crits.
http://wowwiki.wikia.com/wiki/Critical_strike?oldid=119806

And adding in a factor in order to get the values you want is incredible bad practice and unscientific...

Anyway, I don't have any way to run bash script so I translated your code to JS: http://jsfiddle.net/pzrn1hcy/
And I got the exact same results as with my formula, its essentially the same as my code except written differently. I seriously doubt you got the spreadsheet results with the code you posted.

It helps to know how the formula came to be. Its your standard binomial distribution with 4 as the number of trials and crit as the probability:

VcEvSL4.png


Since we want the probability of X > 0 we can do:
P(X > 0) = 1 - P(X = 0)

With k being 0 the first 2 parts can be written off, (N k) = 1 and p^k = 1

This leaves us with P(X > 0) = 1 - (1 - p)^4

However p cannot be only the crit, we have 2 factors that interfere with it: the debuff being resisted and the 12 seconds running out, both can be directly tied to your hit chance. So the formula for 1 lock is then:

1 - (1 - crit*hit*hit)^4

With 2 locks and above we don't have to worry about the debuff expiring, since even if you miss the other locks wont and the chance for the debuff to expire is too small to be relevant. The formula for 2 and above locks is:

1 - (1 - crit*hit)^4

Both our simulations support this.
 

Attachments

  • Capture.PNG
    Capture.PNG
    4 KB · Views: 5
Last edited:
Sorry, forgot we're at university here, lol. It seems you can't stay factual, instead you start insulting me and talking BS. Wow. For what reason? Maybe because you're a stupid a*hole. No more things to add here from my side.
 
Sorry, forgot we're at university here, lol. It seems you can't stay factual, instead you start insulting me and talking BS. Wow. For what reason? Maybe because you're a stupid a*hole. No more things to add here from my side.

What...? Where have I insulted you?
I gave you exactly what you wanted, the formula for ISB and the explanation behind it.

Calling your methods unscientific is not an insult, you can't just eyeball it and scale it by a value in order to get the results you want, that's not how statistics works.

No need to thank me I guess.
 
I havn't seen the theory that the vid shows a full resist rather than a miss. That is entirely possible.
This would mean that it is indeed (1 - hit*crit) rather than (1 - crit), which also fits better with conventional wisdom. Would love to see some evidence either way
 
Top Bottom