RPG Maker VX Ace is ignoring "resist death" flag! Please help!

I have an enemy move that is supposed to kill off the entire party but leave one party member at 1 HP. Before the move goes off, I give the actor a state that has the "state resist: death" flag but when the move goes off, the actor still dies despite having the resist death flag.

The state is definitely being applied because I have an icon for it for debugging purposes that will not be there in the release and the actor does get the status effect icon as soon as I add the status effect to the actor. but the actor STILL dies from the following attack.

This is the state in question:
1688934845836.png



Does anybody know what the problem could be?
How is death being applied? That will determine the causes and fixes.
How is death being applied? That will determine the causes and fixes.
With an attack that does significant HP damage

Devouring Inferno:
1688937527227.png
Ok. And is the state you apply also state 1 in the database? When you take significant HP damage and die due to that, that is what the engine forces to apply is state 1.
Ok. And is the state you apply also state 1 in the database? When you take significant HP damage and die due to that, that is what the engine forces to apply is state 1.
Yes, State 1 is death and that is what I am telling it to resist. State 1 always has been death. My game is not new, been working on it for more than six months.

The resist death state works fine on enemies that I want to do a final attack to try to take the party down with it but refuses to work on this one actor.


Edit: I bet you are all scratching your heads on this one. Google has nothing either. Just a couple people who had their state set to remove after one turn but as you can see, mine is not like that. It seems to be not working for literally no reason.
I feel like this has been addressed ad nauseum in your threads - there is never anything that happens "for literally no reason."

I know you have some number of scripts added to your project, have you tested this with your scripts disabled? It's entirely possible something is altering how the state resist is supposed to work. Have you tested it in a new project?

Especially if it works on enemies but not actors, there should be no differentiation between them in the code - they're all just battlers.

(Side note - "engulfs" does not have an apostrophe)
There should not be anything that alters the state resist. The only script that I have that deals with states is Untargetable State, the one from this @kyonides so unless his has something in it, nothing else should

Here is a list of scripts I have installed. While you cannot see the code inside them, the names should be enough to give an idea of what they do.

If any grabs your attention, I can show you what is in the code:

1688948654196.png



It also turns out that someone else had the same issue a decade ago: https://forums.rpgmakerweb.com/index.php?threads/immortal-status-not-working.16135/

From the looks of it, they never got it fixed.

Here is my event adding the state:
1688949796889.png
I have an enemy move that is supposed to kill off the entire party but leave one party member at 1 HP.
Just to be clear, Death resistance is not supposed to prevent a battler from falling to 0 HP or getting a red name, just from dying to it while the resistance persists.

---

If that's not the issue I'd back up what ATT_Turan already suggested and try out your setup with as few distractions as possible, ideally in a new project, and go from there.
While there really should not be anything that alters state resist in what you've shown, there obviously is, so ruling out some of the more complex possibilities might help getting a clearer picture.

Unless I missed something your state and event do work for me in a fresh project at least.
Except the battler does die or at least is unable to act. The resistant state even gets removed.
I'm trying to figure out what you're actually doing.

Just based on the information presented here:

You have a troop command that triggers your "Immortal" state on a single character.
You then force the enemy via troop command to hit the entire party with an attack that reduces all their HP to zero.
At which point, all the characters "die" instead of one of them still standing with 0 HP.

My guess would be... it's either a plugin or something in your troop events. My guess with the "troop events" is you have something somewhere that says "remove immortal state" and it's triggering early. I'd have to dig through all your troop events and probably the database as well in order to diagnose an "engine issue" problem.

Fortunately, plugin issues are easy to diagnose. Create a new project, recreate the event, commands, etcetera, and see if it works. If it does work... plugin causing problem. If it doesn't... engine issue.

My other question is also one born of practicality:

Why bother with a state at all when you don't need to?
Create an attack that literally does nothing (no damage), but is incredibly flashy (unless for some reason you NEED the damage numbers to appear), and then just set each actor's HP to where you want it. Just check "allow knockout" on the HP to allow them to hit zero HP, and then on the one you want to "stay standing at one HP", you leave the "allow knockout" box unchecked, so they're reduced to just 1 HP only.
It might be due to this:
1688994904356.png


I was under the impression that it left the character with 1 HP but if it does make it go to zero, perhaps I could add a "change HP +1" command to Beautiful Dragon and test after Devouring Inferno is casted. I have to run to the store first. I will post results later.
I've been noticing this for a while. I don't remember if we talked about it before.
My best suggestion would be for you to start a new project.
If in your script section you have japanese characters, then you likely have a pirated version of VX Ace. ( I know, I use to have that as well before I bought it )
If you use the steam version or the one from the forums and start a new project and you install it for english, then you will not get any japanese characters in the script list.
This will fix most problems. I noticed several bugs that were resolved when converting to a paid version (but you have to start a new project as copying over files will keep the bad data).

Other than that, if you really have a paid version then you have something seriously wrong with the installation.

I also advise on testing the death function in a new project.

The code actually kills the character and then sees that you have death resist and removes death state and sets the hp to 1.
what could be altering things is if somewhere you have code that alters the Game_Battler on_restrict method.
It's the latest paid version, but the project was started on a pirated version until I bought it when it was on sale some months ago. The Japanese text is just left over.

But adding +1 HP after Devouring Inferno fixed the issue anyway.
It's the latest paid version, but the project was started on a pirated version until I bought it when it was on sale some months ago. The Japanese text is just left over.

But adding +1 HP after Devouring Inferno fixed the issue anyway.
Yeah, so like I said make a new project and recreate your game, don't copy anything.
It should help to fix problems you are having.
Being that I am really far in development and it is a big game already, I will just work around the issues for the time being because recreating all that I have created will take months.

But I already have ideas for other games so those will probably run more smoothly since they are going to be started on this latest paid version.

But, thanks for your help anyway. At least I figured out what to do to fix this

Original thread: https://forums.rpgmakerweb.com/threads/rpg-maker-vx-ace-is-ignoring-resist-death-flag-please-help.159146/