Ey, so halfway through the second boss fight of my game, the boss summons a bunch of minions and then the minions create a barrier around the boss (I replace the boss with a similar invincible enemy). However, I can't figure out how to make it to where after all the minions (or even one) are defeated, the boss is once again replaced with another unshielded version. Thank you for any help!
Enemy Invincible Until Minions are Defeated
RPG Maker MV SupportI made a battle event page with the "Turn End" condition. I'm not sure it really matters whether the span is set to Turn or Moment. Just don't use Battle or it will run only once in the entire fight.
This is really bad, but it works... kind of. It will only check if the minions are alive or dead at the end of every turn. So even if you kill the last minion at the start of a turn, you have to wait until everyone else has made their move before the boss will change into his vulnerable form. But maybe that works for you, I don't know.
With the plugin Parallel Common Events in Battle I was able to do a little more. First I created a common event with a Parallel trigger.
This event logic is almost identical to what we had before, but the 30 second delay prevents it from running on every frame and possibly causing lag. It will also turn the switch off once the conditions are met which will prevent it from running any more than it needs to.
I added an event page to the battle. It runs on turn 1 and enables the switch that turns the parallel process on. There is almost certainly a better way to do it, but this seems to work.
Code:
◆If:#2 Minion is affected by KOed
◆If:#3 Minion is affected by KOed
◆If:#4 Minion is affected by KOed
◆Enemy Transform:#1 Boss (Shielded), Boss (Unshielded)
◆
:End
◆
:End
◆
:End
This is really bad, but it works... kind of. It will only check if the minions are alive or dead at the end of every turn. So even if you kill the last minion at the start of a turn, you have to wait until everyone else has made their move before the boss will change into his vulnerable form. But maybe that works for you, I don't know.
With the plugin Parallel Common Events in Battle I was able to do a little more. First I created a common event with a Parallel trigger.
Code:
◆If:#2 is affected by KOed
◆If:#3 is affected by KOed
◆If:#4 is affected by KOed
◆Enemy Transform:#1, Boss (Unshielded)
◆Control Switches:#0013 Check Minions Dead = OFF
◆
:End
◆
:End
◆
:End
◆Wait:30 frames
I added an event page to the battle. It runs on turn 1 and enables the switch that turns the parallel process on. There is almost certainly a better way to do it, but this seems to work.
I don't see any reason to actually have two boss battlers and you replace them.
Just give them the Immortal state, then take it off. Or if you don't want them to take damage at all, put whatever parameter modifiers into the state that you'd have on the second enemy.
You can either use events and put the state on when they summon minions then another event that checks for each minion to be dead. Or you can do it a bit more elegantly using Yanfly's Auto Passive States, make the immortal state a passive on the boss then give it
I would also not use Turn End as the condition, because it would be weird from the player's perspective to kill all the minions but you still can't damage the boss for the rest of that turn.
I would make the event triggered by Enemy HP <= 0, then make a copy of the page so it's checking when each of the minions dies. That way you don't need the plugin for the battle parallel events.
Personally, if one were to install a plugin to make this work, I'd use the passive state. No need to have an extra background process running then, and chances are very good that you can find other uses for passives in the combat system.
But this parallel version would certainly be a good solution. I would still suggest using a state that's already in the database over making two entries for the boss enemy.
Just give them the Immortal state, then take it off. Or if you don't want them to take damage at all, put whatever parameter modifiers into the state that you'd have on the second enemy.
You can either use events and put the state on when they summon minions then another event that checks for each minion to be dead. Or you can do it a bit more elegantly using Yanfly's Auto Passive States, make the immortal state a passive on the boss then give it
Code:
<Custom Passive Condition>
condition=$gameTroop.aliveMembers().length>1;
</Custom Passive Condition>
Actually, that's probably what you want. The OP didn't say the minions would get re-summoned (and if they were, they'd have different troop indexes anyway).
I would also not use Turn End as the condition, because it would be weird from the player's perspective to kill all the minions but you still can't damage the boss for the rest of that turn.
I would make the event triggered by Enemy HP <= 0, then make a copy of the page so it's checking when each of the minions dies. That way you don't need the plugin for the battle parallel events.
Probably just a typo, but Wait: 30 is one half of a second 😉
Personally, if one were to install a plugin to make this work, I'd use the passive state. No need to have an extra background process running then, and chances are very good that you can find other uses for passives in the combat system.
But this parallel version would certainly be a good solution. I would still suggest using a state that's already in the database over making two entries for the boss enemy.
Thank you both so much!
you might be able to give the smaller enemies "taunt", so they cannot
attack the boss unles the taunt minions are dead.
however, target all skills might still inflict the boss, so ATT Turans way
might be the best option.
attack the boss unles the taunt minions are dead.
however, target all skills might still inflict the boss, so ATT Turans way
might be the best option.
I was thinking of designing an enemy with this taunt ability, but I can't figure out how to do it. Do you know?
giving taunt is from YEP plugin (YEP_Taunt).
but if you can target all, you still need to nullified the dmg to the boss.
as ATT_Turan mentioned, give the boss immunity to all dmg, and remove
the state when the minions are dead.
you can target the boss with ATT_Turan way, but the dmg would be 0.
you can give taunt to the minions to avoid the boss being targetted,
but target all skill with the state is still better.
it depends how your skills works, and most confortable with.
I dont know if there is another Taunt plugin (or if you own it) as it
might be a paid plugin.
but if you can target all, you still need to nullified the dmg to the boss.
as ATT_Turan mentioned, give the boss immunity to all dmg, and remove
the state when the minions are dead.
you can target the boss with ATT_Turan way, but the dmg would be 0.
you can give taunt to the minions to avoid the boss being targetted,
but target all skill with the state is still better.
it depends how your skills works, and most confortable with.
I dont know if there is another Taunt plugin (or if you own it) as it
might be a paid plugin.
Alrighty. Thank you!
Original thread: https://forums.rpgmakerweb.com/threads/enemy-invincible-until-minions-are-defeated.154664/