Formulas / Calculations for AC and MR?

Discussion on running your own board and editing MajorMUD.
User avatar
syntax
Site Admin
Posts: 517
Joined: Tue Jun 02, 2009 10:02 am

Re: Formulas / Calculations for AC and MR?

Post by syntax »

Here are my results from testing the chance at resisting the spell entirely--
mr-resist-all.png
p.s. The reason for the "yes?" on the first bunch of testing is I thought I had it set to yes, but then later on when I went to change it to "No" for more testing, it was already set to "No." But I couldn't remember if I had changed it already or not. So I did two retests later and verified the results.

Conclusion is the following formula:

Chance to Resist = if( TYPEofRESIST=Never , 0 , IF( ANTI_MAGIC=Yes or TYPEofRESIST=Yes , IF( MR>196 , 0.98 , MR/200 ) , 0 ) )

e.g. ...
  • If the spell's "type of resist" setting is "never", no one can resist it, ever.
  • If the spell's "type of resist" is "no" and Anti-Magic = No then resist chance = 0
  • If the spell's "type of resist" is "yes" or Anti-Magic = Yes and the spell's "type of resist" is anything but "never" then the resist chance is:
    IF MR>196 then 0.98 else MR/200
So there is no benefit to the resist chance for anti-magic compared to non-anti-magic when the resist setting is "yes", but only anti-magic can resist when it's set to "no".

Now I did notice something interesting at the end of my testing, and it looks like you can have a negative damage resistance value which I'm testing now...


User avatar
syntax
Site Admin
Posts: 517
Joined: Tue Jun 02, 2009 10:02 am

Re: Formulas / Calculations for AC and MR?

Post by syntax »

So there is negative reduction for NON-anti-magic classes:
negative_reduction.png
At 0 MR you take 150% of the damage, working up to at 49 MR you take 101% of the damage. Only alteration from that chart is that it looks like MMUD rounds the damage taken down. e.g. the "337.5" damage taken on the last line does 337 damage, not 338.

So the adjusted MR damage resistance formula is--

NON-Anti-Magic: DAMAGE = DAMAGE - ( DAMAGE * IF( MR<50, (MR-50)/100, IF( MR>150, 0.5, (MR-50)/200 ) ) )

(no change) Anti-Magic: DAMAGE = DAMAGE - ( DAMAGE * IF( MR>150 , 0.75 , MR/200 ) )

Chance to Resist Completely = if( TYPEofRESIST=Never , 0 , IF( ANTI_MAGIC=Yes or TYPEofRESIST=Yes , IF( MR>196 , 0.98 , MR/200 ) , 0 ) )


User avatar
syntax
Site Admin
Posts: 517
Joined: Tue Jun 02, 2009 10:02 am

Re: Formulas / Calculations for AC and MR?

Post by syntax »

So I know it has been said that the formula in calculating dodge is complicated, but given the known (observed) chance to dodge, do we know if the mobs chance to strike is one chance cumulative of dodge and AC, or are they separate checks? e.g. if I have an effective 25% reduced hit chance from AC and 10% from dodge, is it once check to hit with a 35% reduced chance, or two separate checks? I would assume the latter, but asking if anyone knows ahead of time before testing it.


User avatar
syntax
Site Admin
Posts: 517
Joined: Tue Jun 02, 2009 10:02 am

Re: Formulas / Calculations for AC and MR?

Post by syntax »

syntax wrote:So I know it has been said that the formula in calculating dodge is complicated, but given the known (observed) chance to dodge, do we know if the mobs chance to strike is one chance cumulative of dodge and AC, or are they separate checks? e.g. if I have an effective 25% reduced hit chance from AC and 10% from dodge, is it once check to hit with a 35% reduced chance, or two separate checks? I would assume the latter, but asking if anyone knows ahead of time before testing it.
Wes wrote: it checks ac first, then dodge


User avatar
syntax
Site Admin
Posts: 517
Joined: Tue Jun 02, 2009 10:02 am

Re: Formulas / Calculations for AC and MR?

Post by syntax »

Wes wrote:it checks ac first, then dodge
Mat wrote:I was always told it checked dodge first. Learn something new everyday.
Brad wrote:I was under the impression that dodge was calculated first as well, but that was simply hearsay from what other people have told me.
Matt wrote:Seems like ti would make more sense if it were first. I'll test it either way and try to verify it.


apathy
Posts: 20
Joined: Tue Feb 23, 2016 12:39 pm

Re: Formulas / Calculations for AC and MR?

Post by apathy »

Easy to check -- max them both out and see which one(s) fire


DeathCow
Posts: 14
Joined: Tue Aug 07, 2012 12:58 am

Re: Formulas / Calculations for AC and MR?

Post by DeathCow »

syntax wrote:
Wes wrote:it checks ac first, then dodge
Mat wrote:I was always told it checked dodge first. Learn something new everyday.
Brad wrote:I was under the impression that dodge was calculated first as well, but that was simply hearsay from what other people have told me.
Matt wrote:Seems like ti would make more sense if it were first. I'll test it either way and try to verify it.

Wes knows whats up. (Thats me)


cuckoorules
Posts: 88
Joined: Fri Mar 30, 2012 9:38 pm

Re: Formulas / Calculations for AC and MR?

Post by cuckoorules »

Did anyone ever do any follow-up testing regarding dodge to confirm the above? I'm not even sure how to approach this. I'd really like to compile a list of things that impact accuracy and secondary defense. I recently learned about party ranks impacting these and of course Illumination plays into accuracy as well. Also, it seems like all of the testing done by Matt was done using monsters attacking a player. Do we know that player accuracy against a monster follows these same formulas for hit and miss% and also the MR and Antimagic stuff? I can make a separate thread and link off if this seems like an unrelated topic.


Post Reply