Tips & Tricks – Second Chance (Kingdom Hearts)

Yanfly Engine Plugins is a plugin library made for RPG Maker MV, a wonderful piece of software to help you make that role playing game of your dreams. You can find out more about RPG Maker MV here.

The Second Chance passive ability in Kingdom Hearts allows the user to survive a fatal blow with 1 HP left. This effect only triggers if the user had more than 1 HP prior to receiving the Fatal Blow. Here’s how to recreate that effect in RPG Maker MV!

You can get the copy and paste code here:

<Custom React Effect>
// Check to see if the party is in battle.
if ($gameParty.inBattle()) {
  // Sets the flag if the target has more than 1 HP at the time of death.
  target._secondChance = target.hp > 1;
}
</Custom React Effect>

<Custom Respond Effect>
// Check to see if the party is in battle, has the Second Chance flag, and if the target is dead with 0 HP.
if ($gameParty.inBattle() && target._secondChance && target.hp <= 0) {
  // Play the revival animation.
  target.startAnimation(49);
  // Set the target's HP to 1.
  target.setHp(1);
}
</Custom Respond Effect>

Enjoy surviving those fatal blows!

Please wait while you are redirected...or Click Here if you do not want to wait.