Is it possible to create an armour/state which reduces the damage done by crits?

I'm trying to make a tank who can counter several elements by entering states designed to be strong against the respective elements. One such is wind which has a higher crit chance and damage in exchange for lower base damage. I want my tank to have the ability to reduce all crit damage taken when in this state.
You would have to use a plugin that lets you create a custom parameter (if there's an existing parameter you don't ever use, and you want to repurpose it to this, that makes it a bit easier).

Then you'd need to make a little plugin to do the reducing of critical damage portion. That's not hard to do, but how you do it is completely dependent on the implementation of your first part.
If it's just one state you might get away without using a parameter. Just take some plugin that lets you control crit rate and return a different rate depending on whether the target has that state or not.
You would have to use a plugin that lets you create a custom parameter (if there's an existing parameter you don't ever use, and you want to repurpose it to this, that makes it a bit easier).

Then you'd need to make a little plugin to do the reducing of critical damage portion. That's not hard to do, but how you do it is completely dependent on the implementation of your first part.
I can use floor damage rate as that is unused in my game, are there any plugins that already exist that could turn that into critical resistance or something like that?
And that's how you want it to function - as a rate? Reducing the critical damage by that percentage?

There's Yanfly's Critical Control, for an obvious starter.

The trick is that the calculation of critical damage is embedded in the middle of the Game_Action.apply() method, which is used and modified by a lot of plugins that have to do with the battle system. So I could paste something pretty simply that would do what you're asking, but if you're using almost any battle plugins, it might break them.

If you're using zero other plugins, I'll paste in the code. But if you're using anything else, you want to make sure your fix is compatible. If you're using Yanfly stuff, there's a plugin parameter in the Critical Control for the universal calculation. Referencing target.fdr as a multiplier will do what you're asking for.
And that's how you want it to function - as a rate? Reducing the critical damage by that percentage?

There's Yanfly's Critical Control, for an obvious starter.

The trick is that the calculation of critical damage is embedded in the middle of the Game_Action.apply() method, which is used and modified by a lot of plugins that have to do with the battle system. So I could paste something pretty simply that would do what you're asking, but if you're using almost any battle plugins, it might break them.

If you're using zero other plugins, I'll paste in the code. But if you're using anything else, you want to make sure your fix is compatible. If you're using Yanfly stuff, there's a plugin parameter in the Critical Control for the universal calculation. Referencing target.fdr as a multiplier will do what you're asking for.
I'm only using a ton of Yanfly's other plugins, I would also like to have it be able to reduce a flat amount of critical damage though this isn't essential
I'm only using a ton of Yanfly's other plugins
Then you should put it into Critical Control, as I mentioned above, for maximum compatibility.

I would also like to have it be able to reduce a flat amount of critical damage
Then I'd suggest using something other than an Sp-parameter, as traits modifying those are multipliers not flat numbers.

Original thread: https://forums.rpgmakerweb.com/threads/is-it-possible-to-create-an-armour-state-which-reduces-the-damage-done-by-crits.157164/