DEF vs Physical Resistance

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
Ah that wondrous esoteric element of physical... (wait huh? anyways...)

• What is the technical difference between the DEF param and the Element Rate > Physical * X%? (Beyond the fact one is flat and one is a percentage).

• To help justify their co-existence, what are some ways these are used in game that doesn't make them in essence duplicate params?
 

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
4,805
Reaction score
5,501
First Language
Indonesian
Primarily Uses
RMVXA
DEF is just a stat, a number, that serves nothing except you're using it as a part of damage formula.

Damage Rate (Physical / Magical) is a sort of damage cut or damage booster that is multipling the final damage.

Whether how you would use it is up to you, and if you're discussing it, I think it should go to Game Mechanics / General Discussion (idk which suit best tough).
 

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
Still not seeing much of a difference. They seem to both cut physical damage. i guess you could use physical resist to boost damage but I’d get the same effect by lowering DEF.

Man you are on top of this what posts go where thing. They should give you a set of keys imo.
 

Aloe Guvner

Walrus
Veteran
Joined
Sep 28, 2017
Messages
1,628
Reaction score
1,071
First Language
English
Primarily Uses
RMMV
Still not seeing much of a difference. They seem to both cut physical damage.
DEF lowers physical damage only if your formula says that it lowers physical damage.
If your damage formula is:
Code:
a.atk * 4
Then DEF has no effect at all. That's the difference, as TheoAllen said DEF is just a number that has no meaning except if you (as the developer) give it meaning, whereas the various rate % params have built-in meanings and adjust the damage outside of the damage formula.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
29,459
Reaction score
6,850
First Language
German
Primarily Uses
RMMV
to be more precise, the physical/magical damage rates in the parameters (which are NOT element rates) are applied to the final damage after the damage formula based on the skill type physical or magical.

element rates are only applied to skills which have that element set as part of their damage settings, which is different from the skill hit type setting - and those are also applied to the result of the damage formula.

and all attributes (ATK, DEF, MAT and MDF especially) have no default function in the engine at all, but are used in the damage formulae only. And how you use them there is entirely up to you, that 4*a.atk - 2*b.def is only the default example - some people change this to a.atk/b.def for example, but that of course requires entirely different balancing.
 

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
First off, love the handle Aloe.

DEF lowers physical damage only if your formula says that it lowers physical damage.
Right, and PDR lowers physical damage if....

to be more precise, the physical/magical damage rates in the parameters (which are NOT element rates)
Shoot sorry, but are you saying PDR is not the param set via "Skills > Damage > Element > Physical in the editor"?

element rates are only applied to skills which have that element set as part of their damage settings
Like the element drop down menu choice of "Physical" for example, right? (I want to make sure we're talking about the same param).

and all attributes (ATK, DEF, MAT and MDF especially) have no default function in the engine at all,
Darn I'm not getting it. I feel that I need to manipulate and apply PDR conditionally for it to be functional in game just as well, no?

I get that DEF is a character stat and PDR is a parameter. I also get that DEF is used in the formula and PDR is (I think) applied after to the formulas final result. But it seems I could then get the same result if I adjusted DEF and then didn't apply PDR, and I keep thinking this way because I am not seeing where/why I would ever need to throw both modifiers at incoming damage. But I am confident I will see an example why if you hang in there with me.

Also a little lost on the real world (aka fake game) application, which may help me grasp this better (more of a visual guy). Is the concept like a protagonist could have heavy armor but then still have a thick hide (or a frail body) under the armor? (Although then i would be looking to HP, personally).

I don't see a similar example of two attributes sort of in the same lane like this. For example I don't see an Evade stat and an Avoidance parameter. So it piqued my curiosity. I want to understand the core distinction to determine if it's different enough to warrant both in my opinion/concepts.
 
Last edited:

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
4,805
Reaction score
5,501
First Language
Indonesian
Primarily Uses
RMVXA
But it seems I could then get the same result if I adjusted DEF and then didn't apply PDR
You can. It's there, as an editor design choice so that you as a dev could pick a choice whether you want to use DEF as flat reduction (or other formula you want) or purely PDR, or both. Your design choice.

There is one difference though, if you use DEF as a same function as PDR, then you have to write it in all of your damage formula. Whereas PDR is already applied to all skills. It's final damage multiplier. You might want a case where the damage formula is not going to include DEF in the formula.
 

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
You can. It's there, as an editor design choice so that you as a dev could pick a choice whether you want to use DEF as flat reduction (or other formula you want) or purely PDR, or both. Your design choice.
OK, so this confirms my initial suspicions and nudges me a bit towards duplicity (at its stripped down core), just in how I build characters and breakdown combat in my mind.

Whereas PDR is already applied to all skills.
Meaning I don't have to set it or call it? It is there with a value and being applied after the damage formula whenever I fire up the engine without me invoking it in some manner?
 
Last edited:

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
4,805
Reaction score
5,501
First Language
Indonesian
Primarily Uses
RMVXA
Meaning I don't have to set it or call it?
You don't have to set it.

It is there with a value and being applied after the damage formula whenever I fire up the engine?
Yes, the formula calculated first, then multiplied.

For example, you have skills 3,4,5,6,7,8 marked as physical. You apply a state that multiply incoming physical damage by 150% to an enemy. So all those skill damage will be multiplied by 150%
 

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
You don't have to set it.
So if I don't give it a value or call upon it, it still exists in my game with a value and is being used in my post damage calculations without my knowledge? Oh crap. Do you know what that default value is off hand? Easy way to turn it off?

Wait... when you said "it was already applied" I asked if it is auto-applied without me having to set it. But now I am wondering if you thought I was asking if I have to set it as in do I have to utilize it. Definitely the former.

Yes, the formula calculated first, then multiplied.

For example, you have skills 3,4,5,6,7,8 marked as physical. You apply a state that multiply incoming physical damage by 150% to an enemy. So all those skill damage will be multiplied by 150%
Understood on the order of operations, but wait... don't I in fact have to "create" that state and "choose" Sp-Parameter PDR and "set" the value to 150% to have this factor into my results/game?
 
Last edited:

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
4,805
Reaction score
5,501
First Language
Indonesian
Primarily Uses
RMVXA
So if I don't give it a value, it still exists in my game with a value and is being used in post damage calculations? Oh crap. Do you know what that default value is off hand? Easy way to turn it off?
The default multiplier is 100%, which it doesn't affect anything at all. Meaning it's already "turned off" by default. Maybe you mistook my statement of "you don't have to set it". Unlike DEF that you need to explicitly write it as a part of damage formula or else it serves nothing. PDR is already integrated in game.

Understood on the order of operations, but don't I have to "create" that state and "choose" PDR and "set" the value to 150% to have this factor into my results?
State here is an example. You can have equipment that apply PDR. Or even in the character itself using trait system.
 

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
Maybe you mistook my statement of "you don't have to set it". Unlike DEF that you need to explicitly write it as a part of damage formula or else it serves nothing. PDR is already integrated in game.
Ha! You'll have to read the bold section in my edited post above.

Regardless, in my mind I have to give DEF a value and invoke it into combat via formula box, just like I have to create and call upon PDR and give it a new value through the editor to "affect anything". Which btw is a huge relief, but again, strictly for me personally, not enough of a distinction. Thank you for helping me come to that conclusion.


State here is an example. You can have equipment that apply PDR. Or even in the character itself using trait system.
Well for the character I would just utilize ATK and DEF, same for weapon/armor. And items have their own damage boxes where I would shoot for the intended consequences sans an extra after damage damage reduction.

So I think I am getting the difference (or lack their of) enough to determine I would probably just go one route or the other (there's enough going on for my feeble mind without having to double up on the damage mitigation component) save some special circumstance that I am unable to dream up atm.

Just wanted to make sure I wasn't missing something profoundly differentiating in their central purpose.

Thanks much.

P.S.
Remember I'm not completely questioning its existence for possible other future scenarios of mine, I did come up with one example of tough (PDR) guy in armor (DEF) - like a nekked human would 100% get cut by a connecting sword, but a nekked Dragonborn wouldn't be hurt as much due to it's scaly skin. And this will help me sleep at night pretending this is why the two attributes coexist... but for the life of me I cannot see why i would ever say that a guy (actor) can punch really hard (ATK) and then a little harder still (PDR > 100%).
 
Last edited:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
29,459
Reaction score
6,850
First Language
German
Primarily Uses
RMMV
there are a lot of differences between DEF and PDR, even technical. And those become obvious if you check the ways to change the values.

DEF is an attribute that is set by graph or formula to be level-dependent as a base, modified by equipment etc.
This means it changes automatically with level advancement based on the actor class.

PDR is a parameter that can only be changed by traits - and traits are fixed in default and difficult to change even with plugins. It can be changed by equipment like DEF, but it will NOT automatically change by leveling.

DEF can be used differently in different skill damage formulae - you can have one skill that uses the regular formula of 4*a.atk - 2* b.def, you can have another skill that goes better through armor by giving that other skill a formula of 4*a.atk - 1* b.def. - or any other option.
The PDR will always be applied to all skills in the same way, it is always multiplied to the result of the damage formula, there is no other way to use it.

So DEF gives you a greater flexibility at the price of needing to enter that flexibility by different damage formulae on different skills, while PDR makes it easier to give a general effect to all skills that does not require much editing.
 

Engr. Adiktuzmiko

Chemical Engineer, Game Developer, Using BlinkBoy'
Veteran
Joined
May 15, 2012
Messages
14,671
Reaction score
2,993
First Language
Tagalog
Primarily Uses
IDK if ur query about PDR and the Damage > Element > Physical is answered so..

PDR modifies damage of all skills that has hit type set to Physical

Element > Physical is a different thing as its an Element (that is why on that list you will also see things like Fire, Ice and so on as long as u didnt edit those yet in the terms tab)

Elements are also used for damage increase/decrease via a different Feature from PDR/MDR which is called "Element Rate"

so basically, to modify damage we actually have these choices

1) Damage formula
2) PDR/MDR (on the Params Tab of Features)
3) Element Rates (on the Rates tab of Features)

punch really hard (ATK) and then a little harder still (PDR > 100%)
Remember though that PDR is a property of the target, not the user

Same goes for element rate, its a target based parameter.

Judging from your OP though, what you really wanted was DEF vs Element Rate, not DEF vs PDR/MDR since your post said "Element Rate > Physical * "

If you want a sample scenario of using DEF versus Element Rates, its could be shown via this example of 2 skills on the same target having different elements

Lets say I have

Fire Slash (DF of a.atk-b.def, element Fire)
Great Slash (DF of a.atk-b.def, element Physical)

If I hit an enemy with the feature "Element Rate physical *50%", my Great Slash will deal only half damage to it while Fire Slash will deal full damage to it even if they have the same damage formula.

Normally, you use the Elements and Element Rates to make enemies that are more/less resistant to certain elements (like a lava monster having huge fire resistance), something you cannot do with manipulating just the DEF stat. It also means that Element Rates will only matter to you if you are actually using different Elements in your skills.
 
Last edited:

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
there are a lot of differences between DEF and PDR, even technical.
OK. I get the inherent different ways they are initially introduced to be manipulated in the engine. In the end just different ways to apply and manage a phys damage modifier. And that's cool, flexibility is great. However I can also award PDR via state to a skill upon leveling up as well, so this cat can definitely be skinned.

I wanted the skinny so I could make a determination if I could conceivably choose one over the other in game and not be losing a completely unique stat/mechanic. Everyone's input has clarified and subsequently made it a very easy decision for me.
PDR modifies damage of all skills that has hit type set to Physical
Aka DEF.

Element > Physical is a different thing as its an Element
Well dag nab it! I inquired about this specifically a few times and it got lost in the shuffle so I assumed I was crazy and moved forward.

I will need to read through your explanations here carefully and return with further questions as you're right this was my initial question, though I did fear PDR was somehow yet a 3rd and separate physical damage modifier which obviously directly factors into my general inquiry.

Head currently spinning, but me thinks fleshing out DEF, from PDR from Element Physical (shorthand term for this?) would be an invaluable conversation for posterity. Hope we can sweep all the eggshells off the floor and get to work here, ya know... what forums are for.

So many things peculating in my brain right now, stay tuned.
 
Last edited:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
29,459
Reaction score
6,850
First Language
German
Primarily Uses
RMMV
However I can also award PDR via state to a skill upon leveling up as well,
no, you can't - not without scripts or plugins. Because all states are removed on death, so if your actor dies then those states are removed.

Additionally, you still haven't grasped the main difference:
Changing PDR will effect all skills in exactly the same way.
Changing DEF can affect different skills in different ways, because you can use DEF differently in different skills.

For example you can make a magic skill that increases damage the more defense your target has - just change the skill formula to 4*a.atk + 2*b.def and the target DEF will increase the damage on that specific skill instead of reducing it.
 

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
no, you can't - not without scripts or plugins.
I was under the impression I could award a skill that had a state that applied PDR.

Because all states are removed on death, so if your actor dies then those states are removed.
My concepts typically revolve around dead characters not needing to maintain states, I'm OK with this in theory.

For example you can make a magic skill that increases damage the more defense your target has - just change the skill formula to 4*a.atk + 2*b.def and the target DEF will increase the damage on that specific skill instead of reducing it.
Following, but I believe I can access and reference PDR in that formula as well, via normal booleans/operators, and increase the targets PDR to the same ends. Or are you saying in this case I can only affect "my" PDR, not a targets, via formula box.

But again, if I wanted the effect you described I feel like I can just apply a state (through various means now that i think of it) that increases damage received via PDR of high DEF characters as i see fit with an event. Not arguing the cleanliness of one method vs the other, depending on circumstances or broader desires, but just ensuring these two components are affecting the same thing in the end, however they get there.

None-the-less your example did help widen the gap between them a bit, thanks Andar.
 
Last edited:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
29,459
Reaction score
6,850
First Language
German
Primarily Uses
RMMV
I was under the impression I could award a skill that had a state that applied PDR.
yes, but that means that the skill has to be used - it is not an automatic effect like the level increase of the DEF.

Following, but I believe I can access and reference PDR in that formula as well, via normal booleans/operators, and lower the targets PDR to the same ends.
no, you can't.
The PDR always gets applied, it can't be removed - the DEF only gets applied if you specifically use it in the damage formula.
Theoretically you could cancel the effect of PDR by including a division for it in the damage formula, but that would require very complex formulae that make absolutely no sense.

The DEF has been defined for simple use and change over time and dynamic effects.
The PDR has been defined for fixed overal effects that are only easy as long as they are general for everything, it is extremely difficult to use it in a dynamic way.

Any try to use the PDR for dynamic, changing effect is usually ten times the work and requires two or three times as complex mathematics as the use of DEF for dynamic effects.
 

bgillisp

Global Moderators
Global Mod
Joined
Jul 2, 2014
Messages
12,704
Reaction score
13,090
First Language
English
Primarily Uses
RMVXA
Personally, I only used DEF and MDEF in my game, and never touched PDR or MDR (or whatever the Magic resistance one is called), and just used element rates to affect damage, as I just felt it was easier to balance. You see, there is one more wrinkle to keep in mind:

PDR applies to any skill with the hit physical trait
MDR applies to any skill with the hit magical trait
If the skill is certain hit, PDR and MDR are ignored

Here's the actual code in ACE for it, under the Game_Battler script. I imagine it will be set up very similarly in MV and in a similar location:

Code:
def make_damage_value(user, item)
    value = item.damage.eval(user, self, $game_variables)
    value *= item_element_rate(user, item)
    value *= pdr if item.physical?
    value *= mdr if item.magical?
    value *= rec if item.damage.recover?
    value = apply_critical(value) if @result.critical
    value = apply_variance(value, item.damage.variance)
    value = apply_guard(value)
    @result.make_damage(value.to_i, item)
  end
 

Guanto

Auteur
Veteran
Joined
Jul 18, 2018
Messages
111
Reaction score
10
First Language
English
Primarily Uses
RMMV
yes, but that means that the skill has to be used - it is not an automatic effect like the level increase of the DEF.
OK skip the skill and just use an event to apply the PDR state at 'level up' to get the same affect.

Lemme chew on all of this while taking a Vitamin D break.
 
Last edited:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

I like Iron Maiden.
Benku wrote on Magnus0808's profile.
Hey man you helped me out a long time ago with a plugin i was wondering if you can help me out one more time since its literally the last thing i need help with if not is cool but id figured id ask you one more soild.
Stream will be live shortly with a guest stream! Tonight, a new guest joins~ Feel free to drop by!
Finally told my boss I need a day off. Tomorrow will be my first in 23 days.
Kind of a goofy question but has the pandemic inspired you in any way?

Forum statistics

Threads
95,421
Messages
929,039
Members
125,650
Latest member
Magidonsa
Top