Elemental damage on one state triggers another skill automatically

Hello,

I would like to be able to put a state on an enemy like "oil" and when it is hit by a fire attack, an "explosion" skill is automatically launched after the attack causing additional damage.

Or for example launch an electric skill on a "wet" enemy, this automatically launches an electric skill on all "wet" enemies as well.

I would like to know, if it is possible to add code in the notepad of the report to detect this and launch an attack accordingly?

THANKS
f it is possible to add code in the notepad
First, notes by themselves do absolutely nothing - you'll always need a plugin to read and process the notes, and that is always limited to the plugin functions.

that said, this can be done in two or three different ways:

1) javascript code in the damage formula can check for states and increase damage.
That is the easiest way, but does not trigger an additional skill

2) there are a few state plugins that allow you to specify code to be executed when the state is activating or dismissed or so. you would have to find a plugin that does this and then write the required javascript code

3) troop events and common events can check for states and skills used and use force-action, but this usually has timing problems because the events are not processed together with the skills.
Thank you for this first feedback, yes I am aware that a plugin is needed for the code in the notepad. I just can't find a plugin that allows to check that (yanfly or other)
I just can't find a plugin that allows to check that
wrong question

you'll need a plugin that allows states to trigger code on receiving damage - those exist.
and then you need to get the javascript commands to check for your specific conditio9ns to place that in the notetag
There have been a bunch of threads about this kind of thing (many specifically mentioning "oil" 😛).

You can do it easily with Yanfly plugins, and you can do it in either direction.

You can put it on the skill with a Post-Damage Eval - check if the target has the oil state and do the extra damage.

Or you can put it on the oil state with a Custom Respond Effect from Yanfly's Buffs & States Core - check whether the incoming attack is fire element, then do the extra damage.

You could even program it all out using Yanfly's Action Sequences and have the skill check for the state and do extra things if it's there.

I recommend doing extra damage and maybe calling an animation rather than actually doing another skill, because Force Action can screw with turn orders and such.

But if you really want it to be a discrete skill, you have several options for making one skill follow another - there's Fomar's Follow Up Skills and Victor Engine's FollowUp Skills.

Original thread: https://forums.rpgmakerweb.com/threads/elemental-damage-on-one-state-triggers-another-skill-automatically.159463/