Howdy, gonna keep it short and sweet. Using MZ.
Basically trying to overwrite the default accuracy formula in how it's calculated for everything.
The only way accuracy/evasion kicks in and takes into effect is when Attacker's Damage is less than Target's Defense.
For example:
So even with an almost 1000 pt difference in Defense and Damage, the Attacker will still have a 9.02% chance to hit
Something like?
That's pretty much it. I thought there was a way to edit there accuracy formula using VS plugins like you could with Yanfly's but maybe I'm overlooking it.
I think this would probably be a plugin request. As now that I'm thinking more about it, this would be fundamentally changing how hits are determined. Since this would technically be calculating your damage then rolling for accuracy check, rather than rolling for accuracy and then damage. But maybe it's simpler to achieve than I'm thinking.
Basically trying to overwrite the default accuracy formula in how it's calculated for everything.
Code:
If DMG >= DEF = 100% Accuracy, Certain Hit, no chance to miss
Same for crits/magic, no critical/magic evasion, if your attack crits, it crits
All rolling against the EVA stat only if DEF > DMG
The only way accuracy/evasion kicks in and takes into effect is when Attacker's Damage is less than Target's Defense.
For example:
Code:
Attack deals 50 Damage with Skill A
Target has 100 Defense
(DEF - DMG) = 50 pt DIFF
Increase evasion by = DIFF / (DIFF + 99)
50 / (50+99) = 33.56% Evasion Rate
Attack deals 50 Damage with Skill A
Target has 51 Defense
(51 - 50) = 1 pt DIFF
1 / (1 + 99) = 1% Evasion Rate
Attack deals 1 Damage with Skill B
Target has 999 Defense
(DEF - DMG) = 998 pt DIFF
998 / (998 + 99) = 90.98% Evasion Rate
Something like?
Code:
const def = target.def;
const diff = def - damage
if (diff <= 0) {
return 0; // 100% hit chance if damage is greater than or equal to defense
} else {
return diff / (diff + 99); // Evasion rate calculation
}
That's pretty much it. I thought there was a way to edit there accuracy formula using VS plugins like you could with Yanfly's but maybe I'm overlooking it.
I think this would probably be a plugin request. As now that I'm thinking more about it, this would be fundamentally changing how hits are determined. Since this would technically be calculating your damage then rolling for accuracy check, rather than rolling for accuracy and then damage. But maybe it's simpler to achieve than I'm thinking.