Skill and Status Alignment

Hello there.


I would like to know if it's possible to cancel a skill attack when enemy has a certain status alignment. For example, the Enemy has "Rage" status. When Player tried to attack the Enemy with "Fire" skill attack, it will not deal any or deal zero damage. The opposite members should also apply.


I am a somewhat beginner to scripting in RPG Maker MV. If this is possible, how how can you implement this? Which method that's involved and need to be overloaded or used, and how they work?


PS: I tried to find the method that runs before the attack, which is "Scene_Battle.prototype.onEnemyOk", but I don't think this one can help me here.
not sure how to do this with javascript but if you want rage to make the player immune to fire based attacks, then in the states settings set elemental rate fire to 0. You can also create special elements in the types, to make other type of skills blockable or buffable. One I like to have is an undead element. So I can have the cleric with a turn undead spell that works only on undead. all non undead mobs will have elemental resist undead 0 while undead I would not have any resist to this spell line at all. 

rage.png
Ah, I see. However, what if the attack has a status alignment? I am asking for a JavaScript-implemented one because some attacks have their own scripts.


Through I appreciate your attempt, @skeezixs1. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/skill-and-status-alignment.73559/