Common Event during Battle Help

Hey so I need help with a specific skill not working. When an enemy reaches 0 MP they automatically gain the State "Insane" (this works and is not a problem), and I want a Skill called Soul Drain to ONLY work on enemies that are currently in the State "Insane".
I tried making the skill call up a common event that checks to see if the enemy is in the "Insane" state, and if they are it gives them the "Soulless" state. However it does not seem to ever give them the "Soulless" state, it does damage and everything but just doesnt add the "Soulless" state to the enemy.
Any way I can fix this or is there another way to do what im trying to do?
Picture related is the Soul Drain skill and the Soulless common event, thanks in advance for any help!
1) a called event has to have trigger=none
NEVER call an event that is set to autorun or parallel process.
those are only to be triggered by their switches, and won't work in battle anyway because the battle has neither autorun nor parallel process handlers

2) to simplyfy your common event, I strongly suggest you remove all else branches from there
at this moment they ignore the targeted enemy and just go from enemy #1 on through all of them.
if you want only the targeted enemy to have the check applied, then you'll need an entirely different structure - and if you want every enemy to have the check applied, then it will work better without the else checking every enemy independently
1) a called event has to have trigger=none
NEVER call an event that is set to autorun or parallel process.
those are only to be triggered by their switches, and won't work in battle anyway because the battle has neither autorun nor parallel process handlers

2) to simplyfy your common event, I strongly suggest you remove all else branches from there
at this moment they ignore the targeted enemy and just go from enemy #1 on through all of them.
if you want only the targeted enemy to have the check applied, then you'll need an entirely different structure - and if you want every enemy to have the check applied, then it will work better without the else checking every enemy independently
I changed the event trigger to none and the Soulless status effect still does not get applied.
And im afraid I dont know how to make the event so only the targeted enemy has the check applied.
Thank you for the quick reply.
OK, that is a bit more complex but the solution had been found decades ago.

1) create an invisible state "target" - no messages, no symbol, no effect - it is just for internal engine handling.

2) give the skill this state to effect the target, before you call the common event effect.
This will put the state as a marker on the enemy that has been targeted by the player

3) in the common event, you'll need the following sequence once for each enemy index:
conditional branch if enemy #1 has state "target"
> conditional branch if enemy #1 has state "insane"
> > apply state "soulless"
> > remove state "target"
> > show text or whatever other things you want to do

repeat above for enemies #2 to #8

Please note that there is no else in that sequence anywhere - you should make sure that the checkbox in the conditional branch to create the else branch remains unused
OK, that is a bit more complex but the solution had been found decades ago.

1) create an invisible state "target" - no messages, no symbol, no effect - it is just for internal engine handling.

2) give the skill this state to effect the target, before you call the common event effect.
This will put the state as a marker on the enemy that has been targeted by the player

3) in the common event, you'll need the following sequence once for each enemy index:
conditional branch if enemy #1 has state "target"
> conditional branch if enemy #1 has state "insane"
> > apply state "soulless"
> > remove state "target"
> > show text or whatever other things you want to do

repeat above for enemies #2 to #8

Please note that there is no else in that sequence anywhere - you should make sure that the checkbox in the conditional branch to create the else branch remains unused
Thank you very much, im still having a problem with it not giving the "Soulless" state though. The common event comes up in battle displaying the text "Tester" that I put there but it still does not apply the "Soulless" State to the Insane enemy.
if the show text comes up but the state is not applied, then something is wrong either with the state or how you check for the state.
Please provide a screenshot of the soulles state and tell how you determine that that state was not applied.
EDIT: from all three states applied please
if the show text comes up but the state is not applied, then something is wrong either with the state or how you check for the state.
Please provide a screenshot of the soulles state and tell how you determine that that state was not applied.
EDIT: from all three states applied please
Thank you for your patience. Here is a screenshot of all 3 states (target, insane, and soulless). The monster also has "
<Passive State: 52>
<JS Passive Condition>
condition=user.mp==0;
</JS Passive Condition>" in their note box.

I know soulless is not being applied because i dont see the icon symbol above the enemy or the message saying the state was applied "#1's Soul has been drained!"
can you make a test project without any plugins, using the same skill and state and common event there?
This should have worked, unless one of your plugins is messing up the engine

EDIT: and please do not cut up and pinch together your screenshots that way. It makes them difficult to read, and sometimes the ID is an important part of what a state does, especially as you already added plugins using state ids.
can you make a test project without any plugins, using the same skill and state and common event there?
This should have worked, unless one of your plugins is messing up the engine

EDIT: and please do not cut up and pinch together your screenshots that way. It makes them difficult to read, and sometimes the ID is an important part of what a state does, especially as you already added plugins using state ids.
Noted.
The only plugin im using is VisuMZ skill state core v1.23, when i turn it off I have the same issue.
I will attempt to make a new test project and test it.
how do you start the battle? how do you get to the enemy at all?

for example if you load a savedgame from just before you encounter an enemy, then that savefile will not automatically contain all the edited data, because the current map is saved into the savefile, and would not be reloaded until the player changes maps.
how do you start the battle? how do you get to the enemy at all?

for example if you load a savedgame from just before you encounter an enemy, then that savefile will not automatically contain all the edited data, because the current map is saved into the savefile, and would not be reloaded until the player changes maps.
Ive just been using the test battle function
the problem with that is that battletest uses shortcuts to get to the battle without going through the entire game setup.
those shortcuts work perfectly with default and some plugins, but a lot of plugins don't work correctly in battletest as a result.

can you test the battle with an evented battle on the starting map in a new game on playtest?
just to make sure that it isn't the shortcuts of the battletest that block the effects?
the problem with that is that battletest uses shortcuts to get to the battle without going through the entire game setup.
those shortcuts work perfectly with default and some plugins, but a lot of plugins don't work correctly in battletest as a result.

can you test the battle with an evented battle on the starting map in a new game on playtest?
just to make sure that it isn't the shortcuts of the battletest that block the effects?
Tried a new game battle event and it still doesnt apply the Soulless state, the common event does come up as the message I put in it appears.
When I make a battle test with a common event that gives the enemy the "insane" state at the start of the battle the Soul Drain skill works fine and the enemy gets the Soulless state. But I dont want to have to start every battle with giving the enemy insane, I want them to get it when they reach 0 MP (which they do, the Insane state symbol comes up when they reach 0 MP but the soul drain skill still does not give them the soulless state).

EDIT
I got rid of the passive condition effect on the monster (when they reach 0 MP they will no longer gain the Passive State Insane) and I instead replaced it with an attack that only becomes available when they are at 0% MP, the attacks makes them Insane, now the Soul Drain ability gives them the state soulless when I use it on them.

Original thread: https://forums.rpgmakerweb.com/threads/common-event-during-battle-help.145965/