OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Headhunter on 18 Aug 2004, 20:34:20

Title: trigger
Post by: Headhunter on 18 Aug 2004, 20:34:20
how do you make so that a trigger only can be activeded what another trigger has been activeded???
Title: Re:trigger
Post by: THobson on 18 Aug 2004, 20:47:55
If I understnd your question correctly.  
Use one trigger to set a variable = true (eg Triggerone = true in the Activation field) and in the condition field of the other trigger have
Triggerone and ....(whatever other condition you need.)
Title: Re:trigger
Post by: Headhunter on 19 Aug 2004, 20:07:40
what i mean is, when you activate the first trigger there is another trigger in the map that can be activated but couldn't be activated before the first trigger was activated, if you know what i mean...
Title: Re:trigger
Post by: dmakatra on 19 Aug 2004, 20:12:51
That is what he said as well. Learn some beginner tutes, its all in there.

:beat: *Gets Shot* :beat:
Title: Re:trigger
Post by: Headhunter on 19 Aug 2004, 20:51:48
i have read a couple of tuts but is haven't brought me any closer to the answer, every time i try it complains about some "reversed variable in expression" i just can't crack the nut...
Title: Re:trigger
Post by: dmakatra on 19 Aug 2004, 20:54:01
Say what you tried to do. What you did and where, etc.

:beat: *Gets Shot* :beat:
Title: Re:trigger
Post by: Planck on 19 Aug 2004, 21:00:32
It means you have used a 'reserved' variable in one of your expressions.

Reserved variables are not to be used in user expressions.........just change the offending variable name.


Planck
Title: Re:trigger
Post by: Headhunter on 19 Aug 2004, 21:11:40
well, i made two triggers, both activated by west, in the first triggers activation field i wrote "trigger=true" (trigger is the name of the other) and the other trigger was placed on top of the other and when activated, but all i get is that stupid error message,
Title: Re:trigger
Post by: Planck on 19 Aug 2004, 21:24:13
Change the name 'trigger to something else......try 'trigone' or something.


Planck
Title: Re:trigger
Post by: Headhunter on 19 Aug 2004, 21:36:20
still no change, isn't there something specific you can write, some command or...
Title: Re:trigger
Post by: Planck on 19 Aug 2004, 21:50:53
In the 'On Activation' field of the first trigger put:

trigone = true

Make sure this trigger is named trigone

In the 'Condition' field of the second trigger put:

trigone and 'whateverelseyouneedtohappen'


Planck
Title: Re:trigger
Post by: Headhunter on 19 Aug 2004, 21:57:36
i still get the error message but is that because i just wrote trigone because i don't need anything the happen, just make a trigger triggable....  ???
Title: Re:trigger
Post by: Planck on 19 Aug 2004, 22:01:52
A trigger detects when something happens.......in this case trigger 2 detects when trigger 1 has been fired.

Sooooooo..........once trigger 2 has detected trigger 1 has been fired........What do you want trigger 2 to do?


Planck
Title: Re:trigger
Post by: Headhunter on 19 Aug 2004, 22:07:24
to activate a script, but in my mission you have already come across the place once so on the return a new trigger on the same place must be activated but it must not be activated on the way in
Title: Re:trigger
Post by: Planck on 19 Aug 2004, 23:22:15
Presumably after you fire the first trigger, you are on the way somewhere else to complete an objective.

So, once the objective is done you could set another variable as true.

So in the second trigger you could have:

trigone and myvariable

in the Condition field.

In the Activation field put what you need to happen.


Planck