MV Reduce the accuracy of an enemy based on its type

Good afternoon, I have a small doubt regarding the "enemy types". I managed to create enemy types thanks to the use of YEP_AutoPassiveStates and while this helps me to modify the elemental damage they receive for being of a certain type, I wanted to know how I can alter other parameters, such as the precision of an enemy, towards a certain character.

I have a character class, called "bird hunter", this class not only causes extra damage to a bird-type enemy, but the enemy will have a harder time landing a hit on that character.

Is there a special plugin for that case or a line of script code that I can use to adjust that parameter?
Is there a special plugin for that case
Yanfly's hit accuracy plugin would allow you to do it, but the issue is that the plugin making it a single line plugin parameter makes it messy if youre trying to add different rules and exceptions.

or a line of script code that I can use to adjust that parameter?
the issue with that approach that i can see is that what you want is no longer a single value on a single battler. birds having a harder time hitting bird hunters requires an adjustment based on an external factor - the target of their current attack.

you could try using Yanfly's Buffs & States' custom state effect notetags to make it so that the bird state applies an accuracy decreasing state to the bird if their target has the bird hunter state and then remove it after the skill. try it with <Custom Initiate Effect> and either <Custom Conclude Effect> or <Custom Action End Effect>

EDIT:
also, if your birds have unique skills you can use victor's hit formula plugin to give the bird skills a lower hit chance on bird hunter targets
the issue with that approach that i can see is that what you want is no longer a single value on a single battler. birds having a harder time hitting bird hunters requires an adjustment based on an external factor - the target of their current attack.

you could try using Yanfly's Buffs & States' custom state effect notetags to make it so that the bird state applies an accuracy decreasing state to the bird if their target has the bird hunter state and then remove it after the skill. try it with <Custom Initiate Effect> and either <Custom Conclude Effect> or <Custom Action End Effect>
Thanks! This was the clue that helped me solve this.

With "YEP_AutoPassiveState" create the state/enemy type "Bird".

Note/Script:

<Custom Initiate Effect>
if (target.isStateAffected(178)) --------------> 178 is a "Hunter Bird" State
{
user.addState(130); --------------------> 130 is "Decrease accuracy" State
}
</Custom Initiate Effect>
<Custom Conclude Effect>
user.removeState(130);
</Custom Conclude Effect>

works perfectly!

Original thread: https://forums.rpgmakerweb.com/threads/reduce-the-accuracy-of-an-enemy-based-on-its-type.175032/