Jump to content
Sign in to follow this  
Funkman

Detect player trigger

Recommended Posts

This should be easy, but I have searched the forums and cant find anything.

How do I set up a trigger to detect if the player is in the trigger area?

Thanks.

Share this post


Link to post
Share on other sites

Activated by anyone present, condition: vehicle player in thisList

Share this post


Link to post
Share on other sites

Celery, you saint. Just saved me creating a new thread. This is exactly what I wanted. Just to confirm and it does seem to be the case - AI wandering into the trigger won't set this off?

Share this post


Link to post
Share on other sites

No because it has to be the player vehicle. Incidentally, as per Celery's example, the reason it's always good to use vehicle x when referencing a unit like this, is because it will also take into account the unit being in an actual vehicle. If the unit is not in a vehicle, then the vehicle is himself.

Share this post


Link to post
Share on other sites

Am I understanding this right then... it will return the vehicle if unit is in one if we do vehicle player? And if he isn't, it'll return the unit?

I ask because I need two separate triggers, one that will only be set off by dismounted players who are not prone and another that will be set off by non prone dismounted players OR player crewed vehicles.

Can this sort of thing be crammed into the condition field if I'm cunning enough?

Share this post


Link to post
Share on other sites
Am I understanding this right then... it will return the vehicle if unit is in one if we do vehicle player? And if he isn't, it'll return the unit?

I ask because I need two separate triggers, one that will only be set off by dismounted players who are not prone and another that will be set off by non prone dismounted players OR player crewed vehicles.

Can this sort of thing be crammed into the condition field if I'm cunning enough?

vehicle player returns the vehicle if he is in one, or the player unit if he isn't.

vehicle player!=player returns true if a player is in a vehicle.

Now that there is a formidable animation mod around, probably the best way to check prone position is player selectionPosition "launcher" select 2<1 - be aware that I don't have the comref handy right now and that the "altitude" threshold is a guess too.

Share this post


Link to post
Share on other sites

Yes, thanks Celery, I saw the biki minutes after I wrote the above.

I see what you're getting at with selection position. Very cunning. :) I'll play with that.

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  

×