[Log in / Register]
| News | Chat | Pastebin | Donations | Tutorials | Rules | Forums |
| Maps | Skins | Icons | Models | Spells | Tools | Jass | Packs | Hosted Projects | Starcraft II Modding | Starcraft II Resources | Galaxy Wiki |
(Keeps Hive Alive)
Go Back   The Hive Workshop > Diablo Franchise > Diablo Discussion


Diablo Discussion Following the unveiling of Diablo III at the Blizzard Entertainment Worldwide Invitational, we've launched this forum to work as a temporary replacement to discuss the Diablo series until we get the entire section up and running.

Closed Thread
 
Thread Tools
Old 06-23-2012, 05:19 AM   #1 (permalink)
Registered User Rispetto
umad?
 
Rispetto's Avatar
 
Join Date: Jul 2009
Posts: 1,118
Rispetto will become famous soon enough (109)Rispetto will become famous soon enough (109)Rispetto will become famous soon enough (109)
Damage Per Second Calculation Mathematical Error

The reason I'm posting this here has absolutely nothing to do with StarCraft II but it still relates as it is an error in math I've seem to run in to, and Sc2 mapmaking has alot to do with variables and math :)

I'm trying to create a spreadsheet as to calculate DPS.
One formula I created myself with a bit of brainstorming,
One I got off a website,
And the third I got off a website as well.

All three lead to the same answer.
However the answer is not correct.
Could it be the right side of all our brains are just duds? Doubtful.
So here I am.
And here's my calculations.

I'll attach 3 spreadsheets, one with my calculation and one with my modified one that contains the one off the website.

The other just got heavily screwed up along the way.. I really don't know how I failed so hard >_>

Though my calculation is done the longer and harder way it still gets the job done in the same fashion.

Now as you can tell when I apply source stats the separation factor (what the spreadsheet tells me is my dps and what diablo does) multiplies by extreme factors.

Attached is a ZIP folder containing everything you'll need.

I need help with this! What am I doing wrong?

Formula
(1 + Passive %) * ((Weapon DPS / Weapon APS) + (Bonus Min Wpn Dmg + Bonus Max Wpn Dmg)/2) * (1 + ( Crit Chance % * Crit Dmg %)) * (1 + (Main Attribute Value / 100)) * ((1 + Attack Speed %) * Weapon APS))
Attached Files
File Type: zip Calcs.zip (5.38 MB, 22 views)
Rispetto is offline  
Old 06-23-2012, 06:27 AM   #2 (permalink)
Registered User Dr Super Good
Imperial Good
 
Dr Super Good's Avatar
 
Join Date: Jan 2005
Posts: 15,194
Dr Super Good has been here far too long (2597)Dr Super Good has been here far too long (2597)Dr Super Good has been here far too long (2597)Dr Super Good has been here far too long (2597)
Merit Badge - Level 0: This user has proven to be extremely valuable to the Warcraft III Modding Community. User of the Year: 2010 
The formula seems to give a good approximation. It was out by less than +/- 50 of the ingame value.

Where this descrepency comes from will need to be investigated.
Dr Super Good is online now  
Old 06-23-2012, 07:29 AM   #3 (permalink)
Registered User Rispetto
umad?
 
Rispetto's Avatar
 
Join Date: Jul 2009
Posts: 1,118
Rispetto will become famous soon enough (109)Rispetto will become famous soon enough (109)Rispetto will become famous soon enough (109)
Quote:
Originally Posted by dr super good View Post
... Where this descrepency comes from will need to be investigated.
>_>

<_<

Try using a 1h wep with an O/H.

It gets very inaccurate at that point... into the thousands.

Maybe it's by the way I'm simply applying the O/H dmg as if it was just +damage to the MH wep?

According to this formula I should have 22.50% more IAS than I have (I have none)
Rispetto is offline  
Old 06-23-2012, 02:02 PM   #4 (permalink)
Registered User Dr Super Good
Imperial Good
 
Dr Super Good's Avatar
 
Join Date: Jan 2005
Posts: 15,194
Dr Super Good has been here far too long (2597)Dr Super Good has been here far too long (2597)Dr Super Good has been here far too long (2597)Dr Super Good has been here far too long (2597)
Merit Badge - Level 0: This user has proven to be extremely valuable to the Warcraft III Modding Community. User of the Year: 2010 
Quote:
Try using a 1h wep with an O/H.
I was...

The way you realized the formula was wrong anyway (offhand damage adds to weapon damage so it is either adding averages or adding min and max values), but the "correct" formula is still out.

I suspect it has something to do with attack rate. The game works in frames internally so it is possible that the Blizzard calculation takes into account frame borders (rounding attacks to appropiate frames) rather than the actual formula which assumes an infinite time resolution. This is why the error is so small and probably non-existant for some attack speed configurations.
Dr Super Good is online now  
Old 06-23-2012, 05:18 PM   #5 (permalink)
Registered User Rispetto
umad?
 
Rispetto's Avatar
 
Join Date: Jul 2009
Posts: 1,118
Rispetto will become famous soon enough (109)Rispetto will become famous soon enough (109)Rispetto will become famous soon enough (109)
Quote:
Originally Posted by Dr Super Good View Post
The way you realized the formula was wrong anyway (offhand damage adds to weapon damage so it is either adding averages or adding min and max values), but the "correct" formula is still out.
That's how I calculated it.

If you notice in the spreadsheet it adds the min / max values from the O/H to the overall min / max which the formula then uses as average wep damage.

Edit: oh wait a second.. in these formulas I tried to skip needing to input min / max to avoid wasting the user's time.

Instead of "min + max / 2" I just did "avg / 2 = min" "avg / 2 = max" then "avg wep dmg = min + max".

Adding any small value would drastically increase the dps.

Now I see what I did wrong.

Seems the only immediate way to fix this is to have whoever is using the calculator to actually input their min / max damage.


Nevermind .. that wouldn't make a difference.

Last edited by Rispetto; 06-24-2012 at 05:48 AM.
Rispetto is offline  
Closed Thread

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


All times are GMT. The time now is 10:13 PM.





Powered by vBulletin
Copyright 2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.5.1 PL2
Copyright © Ralle