Jump to content
Sign in to follow this  
circassian

Killing the Z axis of a trigger

Recommended Posts

Hi guys

How to kill the Z axis of a trigger.. If a plane pass on it doesn't activated, If infantries or vehicles pass over it activate?

Share this post


Link to post
Share on other sites
Hi guys

How to kill the Z axis of a trigger.. If a plane pass on it doesn't activated, If infantries or vehicles pass over it activate?

There are a couple types of condition statments you can use in the trigger:

("LAND" counttype thislist) > 0

or:

this && "Land" countType thislist > 0

You could also "GROUP" the trigger to the units or groups that you want to activate the trigger. This gives you new options in the activation drop down in the trigger window.

Share this post


Link to post
Share on other sites

Thanx Zulu1, what I'm trying to do here is: I have a script of a scud launching... I want the trigger to be active when the rocket hits the ground.. not before.. therefore I was asking how to active the trigger only with X,Y because when the rocket begin to go down to its target the trigger activate before the hit.. and these commands you wrote doesn't works with it

Share this post


Link to post
Share on other sites

The number in the condition > 0 indicates the height in meters. There is really no way to actually disable an axis. You might try increasing the number a bit (=>.2).

edit: Scartch above response. Thinking about it, the scud rocket is not a unit and it will not activate a trigger. The BIS scud you can't do much with, it's mainly for show. BAS has an updated one you might able to work with, and the nuke scuds by DSF and OGG work really well.

Edited by Zulu1

Share this post


Link to post
Share on other sites

Triggers are two dimensional, their activation list will contain all activating units within their radius regardless of height. You should process the trigger's activation list with a script to sort out what to do with it. If you can't modify the addon script to add an effect you could use a delay equal to the flight time used by the scud addon. DSF's flight time is (0.0125 * distance to target) + fixed time for scud to launch and descend. So you can calculate this flight time again in your script and pass that to the effects script to synchronise the effect to the explosion.

E.g. scud launch request script

_pos = _this select 0
_scud = _this select 1
TargetTrigger setpos _pos
TargetLogic setpos _pos
; code that announces scud launch and launches it
_flightTime = (0.0125 * (TargetLogic distance _scud)) + 25
[_flightTime] exec "processTrigger.sqs"
; code that runs after scud launch

processTrigger.sqs

; wait for approximate time for scud to hit
~(_this select 0)
_myList = list TargetTrigger
_i = 0
#lp
_unit = (_myList select _i)
?("LandVehicle" CountType[_unit] != 0): DO SOMETHING BAD TO _unit; goto "next"
?("Man" CountType[_unit] != 0): DO SOMETHING WORSE TO _unit; goto "next"
etc
#next
_i = _i + 1
?(_i < count _myList) : goto "lp"

You may have to adjust the fixed 25 second offset of _flightTime I just worked it out roughly from the DSF script. You can also scale the effect applied to an object by its distance to TargetLogic. Note I'm using a game logic for distance calculations because the trigger will be positioned at sea level, while the game logic will be positioned at ground level.

Edited by *Zeewolf*

Share this post


Link to post
Share on other sites

Thanx Zeewolf but as soon as i mark the target on the map the trigger activate.. seems like it doesn't exec-ting the "processTrigger".

the best thing works is that i unpbo the addon and modified the launching script.. and it's works good

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  

×