Trigger files revisited, directly from Codec:
Trigger files (.tri)
Syntax: Comments start with a / and the rest of the line is ignored.
How many events there are in total:
Then follows an initialisation section that has the following fields. This is read at the start of a new campaign. Section ends with the ENDINIT
This event is set:
This event is cleared (not set):
Redundant, use to set the campaign tempo:
Redundant, use to read a teams priority file:
#CHANGE_PRIORITIES [teamno] [number]
The following only apply to special initialisations.
Bullseye reference point X position. X-position of relative map point to calculate best new Bullseye position (closest FLOT objective to this point will become new bullseye position):
Bullseye reference point Y position. Y-position of relative map point to calculate best new Bullseye position (closest FLOT objective to this point will become new bullseye position):
FLOT sort direction; 0 = West-East, 1 = North-South. 0: Sort FLOT by X-coordinates (default), 1: Sort FLOT by Y-coordinates:
FLOT distance position. Maximum distance between two FLOT objects (in km) to draw a line:
These parameters must be placed in the first setup part between #TOTAL_EVENTS and #ENDINIT.
#BULLSEYE_X 512 #BULLSEYE_Y 512 (center of Korea, which is original value) #FLOT_SORTDIRECTION 0 #FLOT_DRAWDISTANCE 50
End of initialisation section:
The remaining parts can occur anywhere in the file
End of the trigger file - everything else is ignored:
A family of tests for certain conditions chosen from the following:
True if event number has been fired (set in the EVT camp sub file):
True if friendly/enemy team has ground task manager priorityObjective set to [number]:
#IF_MAIN_TARGET [F|E] [number]
True if team friendly/enemy camp_id primary objective has ground_assigned set:
#IF_TROOPS_COMMITTED [F|E] [camp_id]
True if the team controls the list of objectives. With type of 'A' it must own all the objectives in the list, else it must own any of them (and/or logic):
#IF_CONTROLLED [team] [type] [obj list]
True if team has initiative level greater/less than or equal to the number given:
#IF_INITIATIVE [team] [G|L] [number]
True if the team has current stats of greater/less than or equal to the number:
#IF_SUPPLY [team] [G|L] [number]
True if the player option for enemy ground experience is greater/less than or equal to the number:
#IF_PLAYER_DIFFICULTY [G|L] [number]
True if the friendly/enemy team controls more than number objectives:
#IF_PRI_CONTROLLED_LT [F|E] [number]
True if team has ground action offensive type set:
True if force ratio is of the right ratio. - type is A for current aircraft, G for current ground vehicles, N for current no ships, anything else is aircraft + ground The number is calculated for the given team and the opposite team. Then the ratio is (team no * 10) / (opposite number) which to be true must be greater/less than or equal to the number:
#IF_FORCE_RATIO [type] [team] [opposite] [G|L] [number]
True if this many hours have elapsed since the last major campaign event:
If G is present, true if the current campaign day is ]= the number, else true if less that or equal:
#IF_CAMPAIGN_DAY [G|L] [number]
With a G, true if the team has reinforcements ]= number. Else less than or equal:
#IF_REINFORCEMENT [team] [G|L] [number]
True if a random number isless than the given number, which is between 0 and 100:
True if the given condition above is false #ENDIF - closes the:
Play the given movie number:
#IF #PLAY_MOVIE [num]
Change the relations between team and with to the given rel state. If rel is Allied, then the teams merge:
#CHANGE_RELATIONS [team] [with] [rel]
<rel> according to tacedit teams page relations
0 = none. Used or not?
1 = Allied
2 = Friendly
3 = Neutral
4 = Hostile
5 = At War
Set the event number:
Move the initiative by amount from the fromteam to the toteam:
#SHIFT_INITIATIVE [fromteam] [toteam] [amount]
Clear number event:
End the campaign with the given type:
Update the last major event to now:
No longer used:
Supply level for team is set to at least s, fuel is set to at least f and replacements set to at least r:
#SET_MINIMUM_SUPPLIES [team] [s] [f] [r]
For primary objective camp_id, set the teams ground and air priority to the number. This also sets the primary objective flag scripted_priority:
#SET_PAK_PRIORITY [team] [camp_id] [number]
Few entries found in AF tri files, the effect these have are unknown at this time.
#PARENTRECALCDEPTH 4 #FLOT_SORTDISTANCE 20 #MINEVALUATEAIRBASEDISTANCE 20
You can use campaign specific mission.dat file selected with trigger file.
The init section can now contain
to specify a campaign-specific mission.dat. If not specified, normal mission.dat is loaded.
So for example if save2.tri contains
#TOTAL_EVENTS ... ... ... #MISSION_DATFILE missionRF ... ... #ENDINIT
(command must be between TOTAL_EVENTS and ENDINIT), then Falcon loads the mission data of
When the other campaigns .tri files don't contain this line, then they default to the normal mission.dat.
Note that the “.dat” is NOT to be specified in the trigger file, but the file itself must have this extension.
Thus not only each theater but each campaign can have its own mission.dat file now.
Falcon4.aii is switched using
in .tri file.
The default Falcon4.aii is loaded for all modes first to make sure we have valid values (TE uses some variables from there), and then if campaign, the specific one is loaded, or Falcon4.AII when no one is specified.