![]() |
|
Figuring out WDEF - Printable Version +- Southperry.net (https://www.southperry.net) +-- Forum: Maplestory (https://www.southperry.net/forumdisplay.php?fid=15) +--- Forum: Game Mechanics (https://www.southperry.net/forumdisplay.php?fid=33) +--- Thread: Figuring out WDEF (/showthread.php?tid=29906) |
Figuring out WDEF - Fiel - 2010-09-02 Here's the formula. I'm still trying to figure out the variables:
adjust_base_dispense
[spoiler=CalcDamage: Damage]Code: int __thiscall CalcDamage__PDamage(void *this, int MobData, __int64 CharacterData, int BasicStat, int MobAttackInfo, unsigned int a6, char a7, int a8, int a9, unsigned int MobID, int a11, int a12)
adjust_mob_damamge
Figuring out WDEF - Stereo - 2010-09-02 At a guess, a5 in the first equation is the random component, so v5 is effectively "def mastery" in some sense. I haven't worked out exactly what sort of values it'll have yet. Figuring out WDEF - Fiel - 2010-09-02 No, I think the random component is taken care of in the _adjust_mob_damamge (sic) function. Figuring out WDEF - Stereo - 2010-09-02 I mean in player def. In the old system, you have (0.5,0.6)*def as well as the 94%~ mastery on the mob's damage itself. It's not quite structured the same though, hmm. Gotta run through this with some numbers to see what it actually does. Figuring out WDEF - Fiel - 2010-09-02 Speaking of the old system, I can pull up that data as well. Figuring out WDEF - Stereo - 2010-09-02 Okay, I've done some further study and found an interesting result: On very high damage monsters, defense becomes percentage based - roughly half the square root of the defense (as a percent) is used instead of straight up 0.25*def. It basically chooses the best of the 2, in terms of reduction amount. If you have 400 def for example, you end up with 10% or 100 reduced, whichever is bigger. a5 is added to the percentage based def reduction - so it only affects damage taken on mobs with higher damage. It's basically another percentage - a value of 200 in a5 means +200% to the percentage based reduction (to 30% in the above example) I don't know, maybe it is coming from Shield Mastery? If so, PDD around 4500 would be enough to reduce all damage to 1... Figuring out WDEF - PeePeeAyeDeeKay - 2010-09-02 So based on what you say, Stereo, lets see if I got this right.. Given: 10,000 defense 20,000 damage Result: Square Root of 10,000 = 100, 100/2 = 50 --> 50% 10,000 Defense x 25% = 2,500 --> damage reduction of 50% = 10,000 damage reduced vs 2,500 damage reduced = it would be reduced by 10,000 damage since it's the larger amount? You would receive 10,000 damage? EDIT: lol, think I found a miscalc... fixed Figuring out WDEF - Stereo - 2010-09-02 Yeah, it works like that. You do lose 2% per level below the mob though, so it'll do more damage. But you really can't hit it anyway. Figuring out WDEF - Fiel - 2010-09-02 PDD has a constraint of [0, 30000] Mob damage has a constraint of [1, 999999] I threw this at a C compiler btw. So, calculating defense of 30000 and 999999 damage yields the following:
oops
Figuring out WDEF - Stereo - 2010-09-02 Looks the same as what I got, except I used an excel spreadsheet so I can see directly what the code is doing line by line. For short code it seems to be a decent method, though I cheated a little on the if statements. Kudos to Nexon for making defense actually useful I guess - on something with 25k damage my Paladin will only take ~16k due to wdef alone. Figuring out WDEF - Fiel - 2010-09-02 I'm coding a calculator like my other ones. I should have it up and ready in a little bit. EDIT: As a rule of thumb, if you want a mob to do 1 damage to you, you need to have 4x the mob's attack value. Figuring out WDEF - Stereo - 2010-09-02 If you can figure out where a5 came from, it might have an upper bound under 30000 wdef (rather than the impossible 40000 wdef with a5=0) - say you could get a5=150, then you'd only need 6400 wdef to be invincible. For that matter, with a5=17 30000 def would be the same. Figuring out WDEF - Fiel - 2010-09-02 Where are you getting that value from? 6400? Figuring out WDEF - Stereo - 2010-09-02 {[1/(a5+100)*10000]*2}^2 = def It's basically the equation backwards, with the goal being v11=0, which in turn means v5 = 100, so (PDD*.25)^.5*(1+a5/100) = 100 Since a5 is for some reason a whole number percentage, instead of a decimal fraction, it introduces a lot of extra *100 factors in the equation. Figuring out WDEF - Fiel - 2010-09-03 You're making a lot of assumptions about a5. If it means anything, the avoid and hit rate formula also has sections which look like a5. I edited them out since they don't seem to apply to regular players or only apply in very specific scenarios. http://happychinchilla.info/damage.html Figuring out WDEF - Dusk - 2010-09-03 Calculator appears to be non-functional :/ Also, var v11 = (100 - pddSqrt) * mobAttack * 0.01; a5 appears to be nothing more than a % increase to wdef, probably coming from skills like Shield Mastery or equips with +% wdef. Figuring out WDEF - Fiel - 2010-09-03 Dusk, no. If you look further up in the formula the defense is first multiplied by 0.25. So the maximum defense is technically 7500 (30000 * 0.25). The square root of this is about 86%. The calculator should be fixed. Refresh. Figuring out WDEF - shouri - 2010-09-03 So I was looking at the wdef formula WDEF = STR * 1.2 + (DEX + LUK) * 0.5 + INT * 0.4 + [def from equips]? How about def from equips? that should just be added in after right? Figuring out WDEF - Fiel - 2010-09-03 Correct. That formula is for base WDEF. Figuring out WDEF - shouri - 2010-09-03 Fiel Wrote:Correct. That formula is for base WDEF. Figured as much. Thanks for the clarification. |