Jump to content
Sign in to follow this  
MBot

Trigger When No Client Present

Recommended Posts

What I want to do is ending a coop once all players have left the target area. I don't want to use the "BLUFOR not present" activation because there are also AI units in the team, and I fear that if one of those gets stuck it will prevent the mission from ending.

So basically I search a trigger that fires if no human players are present. Is there a easy way to do that ?

Share this post


Link to post
Share on other sites

condition: !player in thislist

should fire the trigger....might have to put a countdown on the trigger so it dosen't fire at start of game .....if trigger is placed before players.

Share this post


Link to post
Share on other sites

Thank you both, I will give it a try later.

Share this post


Link to post
Share on other sites
condition: !player in thislist

should fire the trigger....might have to put a countdown on the trigger so it dosen't fire at start of game .....if trigger is placed before players.

this is not really good for multiplayer, for example on a dedicated server your trigger would fire even with a player left in the area, because this condition is true on the dedicated server (there's no "player" entity)

Try a trigger done like that :

"side X present", "once"

Condition :<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">({isPlayer _x} count thislist) = 0It should work, hopefully

Share this post


Link to post
Share on other sites

I agree that (!player in thislist) will not work in MP. There are equal number of triggers than there are players. So if I was a player, and left the area, my trigger would fire but Client A who was still in the area wouldn't because the only value checked is "player" which is different for every client.

Use what whisper suggests. It basically ensures that all triggers evaluate the same values and fire at the same time.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×