How do you make an event where all the party members must be present?

Hello.
Working on the ending for my game. Need all four of the characters to be present - the player starts with two and the objective is to rescue the other two party members, then take the portal home. Is there some way I can ensure the player actually does rescue the other two party members before trying to go thru portal home and end the game?
Thank you for your time.
Yep. In the event that handles the portal, you can add a conditional branch that checks for the two missing members, and only proceed with the ending if they are.
What engine are you using? "How do I ..." questions belong in the support forum for the specific engine.

If you can only have 4 characters at the most and you need all 4 characters, do Control Variables > Game Data > Other > Party Size (or it might be called Party Members), to get the party size into a variable. Then do a conditional branch to see if that variable is equal to 4. If it's not, one or both of the extra characters is missing.

(that Control Variables option may or may not exist, depending on the engine, which is why it's important for you to post in the correct forum for the engine you're using, and to put it in your thread title, in your profile, or in your post)
Moved to: MZ Support

Original thread: https://forums.rpgmakerweb.com/threads/how-do-you-make-an-event-where-all-the-party-members-must-be-present.147960/