Jump to content
Sign in to follow this  
Mad_Reizka

Trigger not to fire with air units

Recommended Posts

Im working on a MP mission, where I want to spawn units to towns when players are about 1k-500m from the town.

The spawn script works nicely (militarize.sqf) on a trigger I placed over the town with the radius I want but here is the problem:

I want to limit the trigger not to fire if an airunit flies over the trigger. Idea being that if the air unit flies all over the map, it wont spawn the AI into the other towns for nothing.

I want to ease the server load by spawning enemies to towns when needed, so they dont burden the server when they are not needed.

Another question, do I have to add some special isServer stuff to the triggers so they dont fire for each client, but only on server. (So it only fires once, not 60 times)

And Zeus is out of the question since I dont like it :)

Share this post


Link to post
Share on other sites

Add the following to the trigger condition (just put it after whatever you already have):

&& {isTouchingGround _x} count thisList > 0

And the trigger should only fire once if you don't have it set to repeating :).

Share this post


Link to post
Share on other sites

Thanks for your quick reply.

Only condition I have is "this", so:

this && {isTouchingGround _x} count thisList > 0

should work?

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  

×