Download
(12 Kb)
Download
Updated: 06/05/14 06:22 PM
Pictures
File Info
Compatibility:
Craglorn (1.1)
Updated:06/05/14 06:22 PM
Created:05/31/14 01:45 AM
Monthly downloads:21
Total downloads:7,403
Favorites:48
MD5:
MitigationValue  Popular! (More than 5000 hits)
Version: 1.04
by: fosley [More]
1. What is it?
This addon adds an extra pair of stats to the character screen that show the approximate mitigation percentage you currently have. After extensive testing, the new formula appears to be exact for lower-level characters. I still need confirmation it's working for Veteran Ranks.

An options screen is included. You can select to cap the displayed value at 50%, and/or display anything over 50% as a separate percentage. Even though your rating can go arbitrarily high, you'll never get more than a 50% damage reduction, so values over that amount could be misleading.

The addon works with SoftCapInfo and Harven's Extended Stats, but I haven't tested any other addons. It currently doesn't have localization support -- it's only in English. If anyone wants to give me translated strings, I'll learn how to put them in the addon.

For more detail, my formula is:

percentDisplay = (displayRating - 100) / currentLevel

Where currentLevel is 50 for VR1, 51 for VR2, 61 for VR12, etc.

Anything under 0% gets set to 0%, since the game doesn't allow negative damage reduction.

2. How do I install it?
The best way is probably to install Minion from http://minion.mmoui.com. From there, you can search for MitigationValue under the "Find More" tab, then click the "Install" button. Minion will tell you if any addons have been updated, and allow you to install the update. There's even an option to automagically install updates when you run the program.

The other way is to install manually. There is a tutorial at http://www.esoui.com/forums/faq.php?..._howto_install, or you can read my instructions in the included ReadMe.rtf file after downloading (note that you can open the file with any text reader -- the extension is just because .txt files don't play nicely with ESO).

If you install while logged in, type /reloadui <press enter>, then if it doesn't show up, press Escape to open the main menu, click Add-Ons, check "Allow out of date add-ons" if mine is red, check the checkbox next to my addon, click "Reload UI".

3. Change Log
1.04 - Added code that should have been in 1.03 to prevent armor value from dropping below 0%.
- Added code to assume level 50 stats when battle leveling is in play.
1.03 - Updated to a new, improved formula that works better for very low levels and very low armor ratings.
- Updated the font style on my control to match the stock stats controls for those using font replacers.
1.02 - Added an options menu to choose different display methods.
1.01 - The control caps values over 50%, because the game has a 50% hard-cap in damage reduction. So if you have enough rating for 52%, it will display 50%.
1.00 - Release version.

4. Credits
Me, @Fosley.
Harvin and Garkin gave me some lua help on the forums, so thanks!
Septemvri helped me figure out the correct formula, so more thanks!
Seerah for LibAddonMenu (used to display the options menu)

5. Copyright
I'm pretty certain there's a giant bit of legalese we all agreed to that says every addon made for ESO belongs to Zenimax, so as long as they don't care this code is more-or-less public domain.

However, if that legalese somehow doesn't actually apply, or I'm just retarded and can't read, or whatever, here's some stuff I copied out of another guy's addon that looks like it fits the bill (TL;DR: do whatever, just give me credit if you copy my code):
Warning: Spoiler
1.04 - Added code that should have been in 1.03 to prevent armor value from dropping below 0%.
- Added code to assume level 50 stats when battle leveling is in play.
1.03 - Updated to a new, improved formula that works better for very low levels and very low armor ratings.
- Updated the font style on my control to match the stock stats controls for those using font replacers.
1.02 - Added an options menu to choose different display methods.
1.01 - The control caps values over 50%, because the game has a 50% hard-cap in damage reduction. So if you have enough rating for 52%, it will display 50%.
1.00 - Release version.
Optional Files (0)


Archived Files (4)
File Name
Version
Size
Uploader
Date
1.03
12kB
fosley
06/04/14 10:33 PM
1.02
12kB
fosley
06/03/14 02:56 AM
1.01
6kB
fosley
06/01/14 05:21 PM
1.00
6kB
fosley
05/31/14 03:37 AM


Post A Reply Comment Options
Unread 05/31/14, 02:19 AM  
SilverWF
 
SilverWF's Avatar
AddOn Author - Click to view AddOns

Forum posts: 55
File comments: 349
Uploads: 2
Didn't see it anyway
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 03:22 AM  
losti

Forum posts: 0
File comments: 12
Uploads: 0
Same here, German Client
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 03:30 AM  
fosley
AddOn Author - Click to view AddOns

Forum posts: 7
File comments: 33
Uploads: 1
It's because I'm stupid and added the version number to both the folder and the zip file. If you go to your addons directory and rename "MitigationValue v1 00" to "MitigationValue" it should work properly. Otherwise, I uploaded a new file with the correct folder name. Once they've approved it minion should do it correctly.
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 03:34 AM  
losti

Forum posts: 0
File comments: 12
Uploads: 0
Originally Posted by fosley
It's because I'm stupid and added the version number to both the folder and the zip file. If you go to your addons directory and rename "MitigationValue v1 00" to "MitigationValue" it should work properly. Otherwise, I uploaded a new file with the correct folder name. Once they've approved it minion should do it correctly.
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 03:34 AM  
JadeKnightblazer

Forum posts: 24
File comments: 38
Uploads: 0
Thank you very much for this addon!!! Been looking everywhere to find something like this to help out tanks
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 03:41 AM  
fosley
AddOn Author - Click to view AddOns

Forum posts: 7
File comments: 33
Uploads: 1
Made another dumb mistake that won't hurt anything, but you'll suddenly see an addon called "ReadMe" in your list because I used the standard Windows name of ReadMe.txt, and the game sees any .txt file as an addon file.

I renamed the readme file to ReadMe.rtf and uploaded yet again. Any rich text reader can read it, but it's really just a plain text file any regular notepad-style reader can understand also. Assuming people even read readme files these days.
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 06:00 AM  
Seroczynski

Forum posts: 10
File comments: 16
Uploads: 0
Great addition to the stats mate, thanks!
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 08:54 AM  
Namiel

Forum posts: 0
File comments: 12
Uploads: 0
Probably this type of addons (minimalistic, easy and useful) are the best addiction this game could have hope for. Thanks!
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 10:45 AM  
Septemvri

Forum posts: 0
File comments: 2
Uploads: 0
@fosley,

First I want to say you did good job making this addon.

I was following the discussion in SoftcapInfo to see if someone may have additional ideas on defense ratings and mitigation beyond what is speculated before. I just managed to crack the formulas on TF:

defense_rating = char_level * mitigation_percent + 100

where mitigation_percent of 30 and 50 give the soft and hard caps respectively.

You may want to come join the discussion on Tamriel Foundry, I believe there is a lot more work to be done in this field and we may benefit from having you around: http://tamrielfoundry.com/topic/new-...s/#post-511268


P.S. Never simplify a formula just because it may run faster. A multiplication or two more won't hurt the performance at all not to mention how even well known authors here don't buffer their frame refreshes or use low thresholds. Or don't use event subscriptions but yeah, that's another topic


Edit: corrected the sign typo
Last edited by Septemvri : 06/01/14 at 01:35 AM.
Report comment to moderator  
Reply With Quote
Unread 05/31/14, 06:43 PM  
fosley
AddOn Author - Click to view AddOns

Forum posts: 7
File comments: 33
Uploads: 1
I haven't gotten my activation email for TF yet, so I can't post over there. However, you made a mistake in one of the formulae:
A = L*M-100
becomes
M = (A+100)/L
not
M = (A-100)/L

A = Armor from sheet
M = Mitigation percentage
L = Level of character

But the softcap and hardcaps are:
A1600 = L50*M30+100
A2600 = L50*M50+100

So I assume you meant:
A = L*M+100

Which gives the formula you posted on TF:
M = (A-100)/L

Now, the weird part about this formula, is it implies that characters have a negative base armor rating -- that is, a naked character takes *more* damage than the creature does naturally. A level 2 character actually takes double damage with no armor, while a level 50 only takes 2% extra damage, and a VR12 only takes about 1.6% more.

This isn't inherently wrong, but it does mean the calculations start getting messy. If a creature hits you for 200 damage while you're naked, and you have a -20% damage reduction, that means:
200 = actualDamage * (100% - (-20%)) = aD * 1.2
aD = 200 / 1.2 ≈ 167

In general (oD = Observed Damage):
aD = oD / (1 - (-100%/L)) = oD / (1 + 1/L)

The 100% is because the formula above should be:
M = (A-100)%/L
or
M = (A-100)/(L*100)
for complete accuracy.

So, I redid my damage charts to fit this new function, comparing oD at each armor level to the calculated aD for the given level. oRed is the observed reduction, cRed is calculated reduction. RedN is the new formula, RedO is the formula currently in the addon.

Code:
L40 Sorc vs L39 Spider
armor	oRedN	cRedN	diffN	oRedO	cRedO	diffO
0	-2.5%	-2.5%	0.0%	0.0%	0.0%	0.0%
600	10.5%	12.5%	2.0%	12.7%	14.2%	1.5%
1025	21.9%	23.1%	1.2%	23.8%	24.3%	0.5%
1155	25.2%	26.4%	1.2%	27.0%	27.3%	0.4%
1349	30.0%	31.2%	1.2%	31.7%	31.9%	0.2%
1453	32.5%	33.8%	1.3%	34.1%	34.4%	0.3%
1544	34.9%	36.1%	1.2%	36.5%	36.5%	0.0%
1612	36.5%	37.8%	1.3%	38.1%	38.2%	0.1%
1719	39.0%	40.5%	1.5%	40.5%	40.7%	0.2%
1775	46.3%	41.9%	4.4%	47.6%	42.0%	5.6%
1822	47.1%	43.1%	4.1%	48.4%	43.1%	5.3%
1983	43.3%	47.1%	0.8%	47.6%	46.9%	0.7%
2050	47.9%	48.8%	0.8%	49.2%	48.5%	0.7%
2185	48.8%	52.1%	3.4%	50.0%	51.7%	1.7%
There are weird outliers at 1775 and 1822 armor in both cases, which I've been attributing to bad data. I was trying to keep track of 4 armor buffs while people kept killing my spiders and I was having to wait for respawns, so it's possible I just fat-fingered the data or read numbers from the wrong part of the combat log. It's also possible that's valid data and merits attention. Other than the outliers, my formula is consistently closer than yours at level 40.

My level 7 data is a bit thin, but here's the same info:
Code:
L7 DK vs L7 Crocodile
armor	oRedN	cRedN	diffN	oRedO	cRedO	diffO
0	-14.3%	-14.3%	0.0%	0.0%	0.0%	0.0%
150	-1.2%	7.1%	8.3%	11.5%	14.9%	3.4%
255	11.9%	22.1%	10.2%	23.0%	25.3%	2.4%
365	30.7%	37.9%	7.2%	39.3%	36.2%	3.1%
This time both formulae are off by a considerable margin, but mine is again consistently closer.

I did some algebra (the horrors!) and re-configured my formula to use the same variables as yours:
M = 4/13 * A/(30*L+100)

or to save a division:
M = 4*A/(390*L+1300)

Not sure if it helps, but doing more algebra, the 50% reduction is at:
A = (30*L+100)*13/8

And the 30% reduction is at:
A = (30*L+100)*39/40

At level 50, my 50% reduction is at exactly 2600 (that was the basis for my math), and the softcap of 1600 gives about 30.769% reduction.

I'm not saying my math is right, just that it seems to fit my data pretty well. It's quite possible I'm making some bad assumptions, or completely mucking up the algebra, or that I just took bad data.

It's also worth noting that rounding errors in the game's damage calculation are causing low-level characters to seem further off than they should, especially with small attacks. Something that hits for 10 or 20 damage is almost always going to be mitigated to something pretty far from the approximation, so I had to wait around and stand in the red cone to get high enough damage to make any sense. The level 40 test above had a naked damage of 126 on a light attack, while the level 7 test had a naked damage of 61 on a special attack -- heavy attacks were 33 and light attacks were 11, and the percentages get pretty weird on the light attack.

Another thought I have, which I haven't even started working out the math for: a properly set up parabola should be able to hit y(0) = 0, y(softcap) = 0.3, y(hardcap) = 0.5. If it works, it might give a more accurate prediction of what's happening.
Last edited by fosley : 06/01/14 at 04:01 PM.
Report comment to moderator  
Reply With Quote
Unread 06/01/14, 01:35 AM  
Septemvri

Forum posts: 0
File comments: 2
Uploads: 0
Yes, in my previous post here I must have switched the sign - what I meant was "+", will edit it.


I haven't thought that the reverse formula - for mitigation - would produce negative mitigation for sub 100 armored characters and it will be very drastic for level 1 ones. But, hell, why not. First, it gives new characters feeling of superiority when they finally manage to find a white shoulder piece, etc Something more - spell resistance already starts at 120 at level 1 so it makes sense the mitigation formula to be correct as it is.


Originally Posted by fosley
If a creature hits you for 200 damage while you're naked, and you have a -20% damage reduction, that means:
200 = actualDamage * (100% + (-20%)) = aD * 1.2
aD = 200 / 1.2 ≈ 167
Here you made a writing mistake in the sign. It should be 100% - (-20%). But later you continued with correct value


To be able to comment on the rest of the post and particularly on the damage received table, I first want to know what are you taking as base. If there is penalty for having 0 armor, the damage taken at 0 armor shouldn't be taken as base, rather the one with 100 armor. I am participating in these discussions because I'd like to have a public access to the conducted tests - what were the details of the environment, how people tested and what are the actual numbers they observed. For what I know, there isn't high enough damage in this game for us to throw out the rounding factor. What is known about the game so far, in 99% of the cases the game rounds down to the nearest integer (floor). Having the data sample will allow us to have an estimated range of the %s for oRed and cRed, not hard ones, and then start to look for a pattern which can give us the precise rounding formula.


By the way another explanation for the data you have for 1775 and 1822 being off might be if you were backstabbd (+20% damage taken).
Report comment to moderator  
Reply With Quote
Unread 06/01/14, 04:18 PM  
fosley
AddOn Author - Click to view AddOns

Forum posts: 7
File comments: 33
Uploads: 1
Yeah, you're right, I meant to type "- (-20%)". As for the 20% extra damage for the outliers, I don't think so. First, most of the data I know I was facing the enemy, because I wanted to see which attacks were doing which damage amounts. So if anything, those outliers are *extra* damage, so I would need to multiply by 5/6 to get original damage, which makes them even farther from accurate.

If I multiply them by 1.2, there's about the same error, just in the opposite direction (note that all my %diff numbers were absolute value). If I multiply both of them by 1.1 they suddenly get in line which both of our formulae, but I'm not sure that means anything. I could just as easily use 10/9 or use some kind of regression fitting to find the best fit to each curve, but that doesn't mean it should be that way.

Warning: Spoiler


To find the percentage difference, I used the data I posted in the other thread, plus some I apparently didn't post. I didn't use the level 37 zombie or the level 6 DK data in the previous post (note that Display % here is using the old formula from the TF page, not my formula).
Warning: Spoiler


Under my formula, 0 armor is 0 reduction, so I just calculated:
reduction = 1 - damageTaken / unmitigatedDamage

Where unmitigatedDamage is the damage at zero armor.

For your formula, 0 armor is negative reduction, so I used the damage at 0 armor, calculated the negative reduction at that level, and calculated the original damage from the enemy as shown in my previous comment. Then, I used the same reduction formula as on mine, except unmitigatedDamage is from aD = oD / (1 + 1/L), instead of just using oD.

As an example, I'll calculate the 2050 armor value for L40 Sorc vs L39 Spider. First, I got naked and let him hit me to see what his regular attack was doing. It's 126 damage per hit. Then I put on all my armor and appropriate buffs and let him hit me again. It's 64 damage per hit.

Under my algorithm, the assumption is that 126 is the base damage from the spider, so if we divide 64/126 we get the percent of damage remaining after mitigation, and if we do 1-64/126 we get the percentage mitigated. In this case, 49.2%.

Under your algorithm, oD is 126 and L is 40, so we calculate aD = 126/(1+1/40) which is about 122.9. Then, we can use the same formula as in my algorithm to get 1-64/122.9 is 47.9%.

Now, if we equip exactly 100 armor, the spider should do 123 damage if your formula is correct, which would give the original damage more directly. However, it's a lot easier to equip 0 armor than finding the exact pieces to equip 100 armor, so I used the 0 armor values (plus I already had them).

As for how I did my tests: I found some level 39 spiders (I wanted level 40, but didn't find any), then I used various methods to achieve different armor levels (equip different armor sets, switch to shield, add various combinations of buffs), then I stood there and let the spider hit me. I would have my stat screen open, watching to make sure my buffs didn't drop before he hit me, and if it was close I repeated that set of buffs until it was obvious he had hit me well before the buffs fell off. Repeat for the L37 zombie, and the two DK tests.

I'm using T's Combat Stats for my damage information, with everything piped to a single Combat tab so I don't have zone chat and so forth interfering. Unfortunately, my buffs and debuffs aren't showing in the log, so I can't just look for the instant x, y, and z buffs were active and check the next incoming damage. Also, the log doesn't specify crits, enemy ability names, etc., so it can be tricky making sure I'm comparing the correct values, but I try to get several consistent damage values before using them, as well as visually correlating attack animations to damage values.

Edit:
There is definitely not a negative reduction at zero armor. I found a level 22 ogre in Stormhaven (near Shinji's Scarp by the Wind Keep wayshrine), and let him pound on my level 40 Sorc and level 7 DK, both at 0 armor. In both cases, the ogre did 104 damage for a light attack, and 208 damage for a heavy attack, and the death recap screen confirmed these values on both characters. At those values the difference between -2.5% and -14.3% are well above the threshold for rounding errors.

Edit to the Edit:
I went back on my DK with a bunch of armor equipped. He has 240 spell resist regardless of equipment, so that shouldn't affect anything, and the difference between 0 armor and 255+ armor was getting hit for 104 damage vs 60-72 damage (I was using ransack and spiked armor, and wasn't looking at exact values -- just wanted to confirm that armor did decrease the damage, and it wasn't somehow a magical fist attack).

Also of note: T's Combat Stats *does* report critical hits. I just never saw one before, so I didn't realize it. The ogre critically hit me for 96 damage, but I'm not sure what armor rating I was at when he hit me.
Last edited by fosley : 06/01/14 at 05:03 PM.
Report comment to moderator  
Reply With Quote
Unread 06/01/14, 05:22 PM  
fosley
AddOn Author - Click to view AddOns

Forum posts: 7
File comments: 33
Uploads: 1
I made a slight update to the addon at the request of several users. The labels will now cap at 50% even though your rating could be higher.

Because the formula isn't known to be completely accurate, you might still get some use out of a slightly higher rating, but it shouldn't be much. Version 1.00 is still listed under archives if you'd rather use it to display values over 50%.
Report comment to moderator  
Reply With Quote
Unread 06/02/14, 03:54 AM  
JadeKnightblazer

Forum posts: 24
File comments: 38
Uploads: 0
Originally Posted by fosley
I made a slight update to the addon at the request of several users. The labels will now cap at 50% even though your rating could be higher.

Because the formula isn't known to be completely accurate, you might still get some use out of a slightly higher rating, but it shouldn't be much. Version 1.00 is still listed under archives if you'd rather use it to display values over 50%.
As a fellow Addon/ Mod Maker (I do Minecraft), having to maintain two styles of the same addon gets old fast.

How about the Softcap approach to this? Display anything higher then 50% as the red + numbers afterwards.

1.That way both mods look/ display the data in the same way
2. Over achiver players can see their % over head.
3. Min/maxers can adjust their armor ratings to max out right at the cap with spell buffs. So they waste stats into an unknown over hardcap.
4. Most important, less hassle for you in the future
Last edited by JadeKnightblazer : 06/02/14 at 08:07 PM.
Report comment to moderator  
Reply With Quote
Unread 06/03/14, 01:37 AM  
fosley
AddOn Author - Click to view AddOns

Forum posts: 7
File comments: 33
Uploads: 1
Version 1.02 adds an options menu so you can change the display as you like. One option toggles between capped and uncapped values, and the second option toggles display of excess value separately, as suggested by JadeKnightblazer.

The third image under "pictures" shows the different possibilities. You probably don't want to show excess separately without having the primary value capped, but you can do it if you choose.
Last edited by fosley : 06/03/14 at 01:40 AM.
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: