Ending a Battle Once Specific Enemies Defeated?

Hi fellow GameMakers!


I'm a bit new to RPG Maker in general and I'm working obsessively on my first game!


However... I am a bit stuck as I'm trying to make a different kind of boss fight and can't quite get the programming right. 


I'll try to make this as sensible as possible -


Basically I have a boss fight with "A" as the main enemy with "B" and "C" as smaller assisting mobs.


Simply put, "A" is not an enemy I want to be defeated. 


Ultimately, it's along the lines of "B" and "C" are controlling "A" and the party needs to defeat them to successfully get through the battle, as "A' is a friendly character we want to recruit who has just "gone" bad due to mind-control and such.  
 


Rather, I have a key item to be used in battle that ultimately prevents "A" from using any offensive moves. I have "A" set to basically be an unkillable killing machine at this stage in the game so that just trying to battle as normal will always result in a Game Over. Instead, I want the party to be prompted to work at defeating "B" and "C" while one person consistently uses the key item each turn to keep "A" from one-shot KO-ing the party. Once "B" and "C" are defeated, the battle will end thus starting a cutscene and so on and so forth. 


I've figured out the event conditions such that if the key item is used, "A" will not attack but if it isn't, "A" basically terminates everyone.


That seems to be working okay. 


However, I can't figure out how to end the battle once "B" and "C" are defeated. 


Is this something that can be done with switches or do I need to try something else?


Any help is greatly appreciated, as I am still learning and this first game of mine is a surprise for a person for a close to me! 🙂


 
use the abort battle command at that position, or use a force-action with the escape skill on the enemy depending on what you want to display as messages (both in the troop event that does the rest)
Thank you Andar, I completely missed the Abort Battle option!


Now I want to ask about the whole key item business... I thought I had it right but it isn't working.

I'll try to explain what I have going on here and show some screenshots as best as I can - 


I've set up the key item that when used runs a common event. 


The common event sets a switch on saying the item has been used. 


The enemy's AI seems to be the issue. I want it to use "Terminate" if it hasn't been used and "Hesitate" if it has. 
I also need to set the switch off again after the enemy's turn, as I want the Key Item used every turn. 

Any thoughts are greatly appreciated!
I'm loving RMMV so far and having a blast figuring (err, trying at least) it all out!


On a sidenote, the first event tab in the battle window is just plot text. 

MECHORGI'S AI.png

COMMON EVENT.png

KEY ITEM.png
Call Common event only works if the common event has "Trigger = None"


Parallel processes won't work on battlescreen (or on any other screen) either, they will only happen while on map


Most probably you need to change the span of the troop event - that indicates how long it will run, and "Battle" means exactly once per battle (which means the condition can't be checked a second time), turn is usually better with variable events

Original thread: https://forums.rpgmakerweb.com/threads/ending-a-battle-once-specific-enemies-defeated.59774/