Subject: Tutorial: Using Text in Missions and Campaigns
Location: Texas, U.S.A.
Member Is Offline
Mood: Not enough hours in a day
posted on 3-9-10 at 14:06
Tutorial: Using Text in Missions and Campaigns
This tutorial will look over the various files needed to get text into your mission or campaign.
Almost all text seen during a singleplayer or Co-op mission comes from a special file called a .BIN file. All of the wanted text inside the .BIN is
organized into "strings." When the game wants to display a text string, it looks in the .BIN file for a particular call-name, pulls the string out
of the BIN, and finally displays it on the screen wherever it needs to be. If another string needs to be displayed, it goes back into the .BIN and
pulls it out.
From a map makers standpoint, this can be a little daunting as it is "one more thing to worry about."
Some of the more experienced map makers may be thinking right now "Why not just use a WAC to display the text?" This will be explained later in
"BIN vs. WAC (text-wise)" further down.
Breakdown of a BIN
BIN's are grouped into various sections by lines of code such as this:
The grouping is fairly standard, and you'll do well to obtain a copy of the default.BIN to use as a template/study guide.
Text strings are found in BIN's, and are assigned a unique callname:
Title = "Night Trap"
In the example above, the callname is the leftmost word "Title."
Whenever and where ever the game calls upon the text string "Title" the text inside the quotes (in this case it would be "Night Trap") is
automatically sent to the screen where it is needed.
There are some standardize callnames that should not be used for any other purpose than what is listed here, these are:
The Title of the Map. This is used
not only in the mission selection screen, but also shows up on the multiplayer server selection screen.
This is the briefing (only) shown on the Singleplayer mission selection
This is the brifing (only) shown in-game by pressing the Objectives key (O by
This is the briefing (only) shown on the insertion/death screen by clicking the
This is the debriefing shown on the end-misison screen when you have
successfully completed the mission.
This is the debriefing show on the end-mission screen when you have failed a
These strings are used for the waypoint names that show up
near your Map compass in-game. Waypoints are given names in the MED under the "Name" dropdown box (See picture)
'[WinConditions]' *Note 1
These strings are used in the MED under the "Win
Conditions" on the map's General Info page.
These strings are used on the Directives or Goals list (default key G
in-game). You typically need an Event or WAC command to get them to show up.
These strings are typically shown in the Radio messages whenever a Directive has
'[LoseConditions]' *Note 1
These strings are used in the MED under the Loose Conditions in the map's General Info page.
These strings may be shown on the player's Goal list (default G key). You typically need an Event or WAC command to get them to
These strings are used when a Lose condition is met... to tell the player they seriously F'd up somewhere.
'[People Names]' *Note 1, Note 2
These strings are used to give AI custom player names by using the two boxes found in the MED. (See Picture)
Unknown in DFx, DFx2. Possibly used in JO in the opening of the mission or maybe for a C4 style mission movie.
'[AINames]' *Note 2
This is used to hide the players name when driving in 3rd person veiw
This is used when an AI has no name and doesn't use the JO naming system. This is also used when a player's name hasn't been
loaded yet in multiplayer games.
For the ###'s in the Win and Lose condition groups, as well as in the PeopleNames, the number 000 is reserved as a
AI Naming is done in two ways, the JO method and the classic method:
JO Method has supposed ranking of the AI's next to their names, which both are generated at random at the start of the mission when no ID# is
Classic method only has what is in the BIN's, i.e. BLACK_WIDOW = "Black Widow" and does not include ranking.
Text from WAC's
There are several WAC commands that will output text to either the Radio chatter or the System console.
This command will output text to the Radio chatter.
text#(" ",v# )
This command will output text to the Radio chatter, in addition it will output the value of a mission variable right
This will output text to the System console
This will output text to the System console, with the value of a mission variable right after.
BIN vs. WAC (text-wise)
BIN's hold all text for a mission. Since there's only text strings in the BIN's, the mapper or modder does not have to worry about messing up a
logic chain just to change a text message or two.
BIN's can be swapped out on a per user basis. Provided that the text string callnames are the same, different BIN's can churn out different messages
on the same mission. For example, on one player's screen he sees "Mission Complete, Bravo" while another player sees the exact same misison in a
WAC's do not require each user to have the file on their computer in order to see the text. This is very useful for maps that are not in installed
stock or Mod campaign, because only the host server needs to have the WAC.
WAC's unfortunately do not contain the briefing, which only BIN's can contain.
In short, use BIN's for singleplayer-only text, use WAC's for multiplayer text.
Campaign names that show up on the singleplayer menu are located inside the Game.BIN, which shouldn't be altered unless your making new campaign(s)
for a Mod.
They are located under the '[CampaignMenu]' and '[Campaign]' headers, and are typically at the very bottom of the file.
Unlike the mission text, which is used by the game via the MED or NILE map files, the campaign text is specified inside of the campaign.def.
is used for the campaign names, * is usually replaced by a color name.
is used for the campaign briefing, * is usually replaced by a color name.
The Campaign.def also allows you to organize and setup your campaigns and missions, but that is for another tutorial.