Create a state where user survives with 1 HP.

rambunctiousRPG

Villager
Member
Joined
Jul 2, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMMZ
I'm trying to create a state that makes the user survives any attack with 1 HP,

the skill basically replicates the move "Endure" from Pokemon.

Unfortunately, the other posts on this topic are only specific to MV, not MZ - as they require Yanfly Engine plugins.

Is there a way to do this in MZ? All help is appreciated!
 

Milennin

"With a bang and a boom!"
Veteran
Joined
Feb 7, 2013
Messages
2,994
Reaction score
2,227
First Language
English
Primarily Uses
RMMV
The non-plugin way is to give the character Death Resist, then at the end of every turn in battle, check if their HP is 0, and set it to 1. Remove Death Resist when the character is no longer affected by it.
 

rambunctiousRPG

Villager
Member
Joined
Jul 2, 2021
Messages
7
Reaction score
1
First Language
English
Primarily Uses
RMMZ
The non-plugin way is to give the character Death Resist, then at the end of every turn in battle, check if their HP is 0, and set it to 1. Remove Death Resist when the character is no longer affected by it.
How to check if their HP is <= 0 through states?

1634475644723.png
 

Milennin

"With a bang and a boom!"
Veteran
Joined
Feb 7, 2013
Messages
2,994
Reaction score
2,227
First Language
English
Primarily Uses
RMMV
You do that in troops events. Call the Common Event that checks the HP.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
34,321
Reaction score
8,755
First Language
German
Primarily Uses
RMMV
How to check if their HP is <= 0 through states?
or in any other event than troop events, you use control variable to load the current HP into a variable and then conditional branch to check that variable.
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
2,791
Reaction score
1,638
First Language
English
Primarily Uses
RMMV
And, really, all of this would work equivalently in MV. If you're finding answers/posts that do something different or more complex than this, that actually required the custom scripting in the Buffs & States Core, the MZ equivalent to Yanfly is the VisuStella library.
 

Latest Threads

Latest Profile Posts

a lot of my maps and battlebacks are me redrawing base rpg maker mv stuff to match with my own artwork... sometimes it comes out ok lol.
Guess I had to do something related to xmas... :kaoswt2:
SWZtrkz.jpg
"16. Do NOT contact other members by private message, on the forum or status feed, inviting them to put additional tools (such as leaderboards, ads, etc - whether yours or another person's) into their game."
Oh no. Necessity is the mother of invention. Do I want to know what happened?

Forum statistics

Threads
117,183
Messages
1,105,272
Members
153,312
Latest member
Homaniac
Top