Description.ext tutorial
- by Hangfyre

Main menu


 

EXT Sound Tutorial.

 

We've all played the maps where you could chose different weapons in the briefing before the mission starts. Well, this is done via the description.ext file.
and here's how you can do it for your custom maps.

EDIT


Thanks to KnYnE for emailing me about an error in the example file. A misplaced ";" sorta screws you :).
Anyway, i've fixed that bug, plus updated the example file to include the strings for the new weapons released in the Beta 1.29 Patch. These are :
MM1 / 6G30 / Bizon / Steyr / G36a


Please note, this is NOT a comprehensive tutorial on everything you can do with the description.ext file. It covers the basics most people have asked for. More details on the other functions will follow......

A quick word on files first ...
You add the description.ext into the mission folder. The same place as the mission.sqm. This folder is hiding in the /operationflashpoint/users/ /missions/ folder. You must have saved the map you're working on, so the mission folder is there. Please note, save the mission as a user mission and do not export it. Exporting the mission creates the mission pbo file.

The pbo file is basiclly just the mission folder wrapped up into one file. As such, once you export the mission, you can't edit the files inside the pbo. What i find works best is this.
Open the editor, and get the basics of your custom mission worked out. That is, the location on the island, and place a Player unit. Then save the mission as a user mission and exit the game. Open the /operationflashpoint/users/ /missions/ folder, and create your description.ext file. It's really just a text file, but i've included a sample description.ext file HERE for you to download.

It's really personal preference as to which order you do this. You can edit the description.ext file either before, during or after you put your map together. Or you can be like me and edit it constantly throughout the mission making process :). The major pain-in-the-ass with the editor is the inability to check the description.ext file during the preview. This means that to check your description.ext is working, you need to export the mission, and play it. This is a problem, as you must exit the game to delete the old pbo file before you can save the mission again. It's a real drawback that the editor does not save over missions :(

end of files stuff :)

What can the description.ext file do for you ??

well, you can set the respawn method and time, add more weapon options at the briefing stage, set whether the watch,radio, or GPS are available during a mission, or even stop the map itself from displaying !

And it's all nice and simple too :)

Respawn Options



Suits has put together a nice little bit of info on respawning, and here it is :-


Modes
NONE - no respawn
BIRD - as seagull (default)
INSTANT - at place you last died
BASE - at your base ( set with markers "Respawn_West", "Respawn_East")
GROUP - into a remaining soldier of your group (assigned group/platoon)
SIDE - into a remaining soldier of your side (east, west)

The respawn modes are set in a description.ext file located with your mission.sqm in a folder. The description.ext is just a text file, so you can make one with notepad. Add it in the same folder as your mission.sqm before exporting to a multiplayer mission. (PBO file)

Here is the text you will need to add to the description.ext.

respawn = "mode"
respawndelay = time


-Change type to one of the respawn modes from the list above. example : respawn = "instant"
-Change time to any number. This sets the time before the player can respawn in seconds. example : respawndelay = 20

To make a BASE respawn you will have to add 2 makers in your mission. One called Respawn_West and the other Respawn_East. Place the markers where you want the players to respawn at.

Note in the earlier releases of the game Group only allowed the commander of the group to spawn into other AI members. Also SIDE respawn had some weird effects as well. I dont know if the have been fixed with the new patch or not.


Many thanks to Suits for that. Saved me writing it :)



In the example description.ext i've listed the various respawn modes again, to make it easier for you :)
As an additional note, you can also use numbers instead of the respawn modes...

1 = None
2= Seagull
3 = Instant
4 = Base
5 = Group
6 = Side


So you can use ....
respawn = X
respawndelay = time

where X is the number.


Map Options



Another easy section. For most of the options here, it's either a yes or no answer.
0 = No
1 = Yes.

really personal preference and map design for what is visible. At a minimum, allow the compass to be seen. Unless you want to be cruel :)

The 2 title options are pretty easy too. Just substitute the text you want the player(s) to see.


Weapon Options



And we come to the main reason for this tutorial :)

This section lets you chose additional weapons and equipment that is available to the player(s). This works for both MP and SP maps.
The basic outline for each weapon looks like this :-


class Weapons
{
class AK74;
{
count = 0
};

To add weapons, just change the "0" to however many you want to add.

It's the same for ammo..


class Magazines
{
class AK74
{
count = 0
};


If you look at the sample file i provided, you should notice that i've separated the different sides weapons. You can mix'n'max happily. That is, you only need one "Class Weapons" section, and one "Class magazines" section.

Also, more importantly, note that at the end of each section there is 2 "};" lnes. This tells the game that the section has ended. As such it's vital that these 2 lines are included.
Also, make sure to place the Magazines section AFTER the weapons section.

Ok then, that about wraps this up. feel free to email me at the address below if you have any questions....

 

 

Sound/Music Tutorial
- by Hangfyre


Sounds, Music and Speech are some of the most interesting aspects of mission-making in OFP. The inclusion of any/all of them can take a mission to a new level of fun. For example, the mission "Air Cavalry" by Kyllikki includes a Jimi Hendrix song during a chopper ride. I made special note of this during the review, as it was enjoyed by all the players at the time.

Let's face it, long chopper/boat/truck rides can be really boring with nothing to listen to or do :). Until the use of voice comms becomes prevalent, most players ( in my experience ) only use text-chat to communicate. A little extraneous noise goes a long way.

how hard is it ?
It's relatively time consuming, but not technically difficult. You need to be comfortable with the description.ext file, and have a basic understanding of csv files. Thankfully, you can pretty much all the work in notepad :)

What do i need ?
A decent audio editor, such as : Wavelab, SoundForge etc
A converter from wav to ogg format :

Use this little gem here

To make your own voices, a microphone and a decent soundcard are vital

For automated voices try these sites.
Rhetorical Voice
AT&T Labs
Bell Labs

A bit of inguenity and flair comes in handy too :)

One thing i've found absolutely VITAL, is friends. Espicially friends who can do accents. Nothing starts a good conversation over icq like me sending out messages to everybody "Anyone do a decent accent ??? " :)
Anyway, how you acquire your audio files is really personal preference. Personally, i use friends voices for the basic speech, and grab music from whatever i like.

Onto formats... this stuff will make or break you. OFP can be very twitchy when it comes to the settings of the audio files.
What works is this 16 bit, 44100 kilohertz, 64 kps bit rate
The funky it is in the stereo / mono aspect. Music is fine in Stereo or Mono, but Speech and Radio MUST be in Mono.

Once you've got your wav files, start up the Egg Drop, the converter listed up above. It's a simple case of drag-n-drop. Drag the file onto the cute little window of Egg Converter, and converts the wav to ogg format. One thing to note about Egg Drop is the default bit-rate is 80kps. You have to change this every time you start the program.

Ok, so now you've got the ogg files you want. You need to add a couple folders to your mission folder. Like this :



As you can see, the two "new" folders are "sound" and "music"

Music = any music files you want to include
Sound = everything else. Speech and Radio

That's the hardest bits done. The rest is pretty much cut-n-paste.
Moving onto the Description.ext file. You need to declare all the audio files you will be using, in their respective classes, Music, Sound ( speech ) , and Radio.

Lets start with the Music class first....

class CfgMusic // Overall class name
{
tracks[]={musicfilename};
// declaring the music file's name
class musicfilename
// the actual declaration
{
name = "";
sound[] = {musicmusicfilename.ogg, db+30, 1.0};
// declares which ogg file to use
};
};


Now, the first thing you're probably saying is "What the f*ck ?? " Relax, it's pretty straight-forward.
Important things to note.
* like all classes, you must start with " { " and end with " }; "
* Syntax is vital, so make sure you don't have any spelling errors.
* "sound[] = {musicmusicfilename.ogg, db+30, 1.0}; is the vital line. You're telling OFP the name/location of the file to use
* db+30 is the volume the file is to be played at
* 1.0 is the relative pitch of the file. If you want it to sound exactly as it did when you created it, leave this at 1.0

There's no real biggies here. The example file has this code, minus the comments.

Onto the next class, Radio,

class CfgRadio
{
sounds[] = {radiofilename};
class radiofilename
{
name = "";
sound[] = {"radiofilename.ogg", db+0, 1.0};
title = $STRM_radiofilename;
};
};


As you can see, it's pretty much indentical to the Music class.

* title = $STRM_radiofilename; tells OFP which text string to display. this ties in with the Stringtable.csv file

And now for Sounds

class CfgSounds
{
sounds[] = {soundfilename};
class soundfilename
{
name = "";
sound[] = {" soundfilename ", db-40, 1.0};
titles[] =
{
0, $STRM_ soundfilename
};
};


It's is damn-near identical to the Radio class, with minor differences.

OK, moving on to the Stringtable.csv file. This is straightforward.

LANGUAGE,English,Comment
STRM_musicfilename,
STRM_radiofilename, **text** .,
STRM_soundfilename, **text** .,


This is obviously only the english side. Seeing as i don't speak French or Italian or Spanish or German i leave out the translations :)

The Stringtable.csv is where title = $STRM_radiofilename; is referred to. Notice that the " $ " has been dropped however. It is vital that both strings are indentical, except for the " $ ". Otherwise, you won't hear diddly-shit in-game.

The " **text** " is whatever you want for the Sounds/Radio. You can happily leave it out, but make sure the punctuation remains. The example file is a good place to look about now :)

That's pretty much it for stuff outside the editor. Time to start up OFP...

There's about a dozen or so commands you can use to implement the audio files you've slaved over.....

Radio
Enable Radio = Set to False for no radio messages, True to receive radio messages
Syntax EnableRadio TRUE/FALSE
GroupRadio = members of your group receive what you transmit
Syntax unitname GroupRadio "radiofilename"
VehicleRadio = all units in your current vehicle receive what you transmit
Syntax unitname VehicleRadio "radiofilename"
SideRadio = all units on your side receive what you transmit
Syntax unitname SideRadio "radiofilename"
GlobalRadio = all units in the game receive what you transmit
Syntax unitname GlobalRadio "radiofilename"

Music
PlayMusic = plays a music file
Syntax PlayMusic "musicfilename"
FadeMusic = changes the volume of music. Time is the length the change is to take place over. volume is any number.
volume > 1 = increase volume | volume < 1 = decrease sound
Syntax time FadeMusic volume

Speech / Sounds
Say - gets a unit to say something
Syntax unitname Say "soundfilename"
FadeSound = changes the volume of a sound. Time is the length the change is to take place over. volume is any number.
volume > 1 = increase volume | volume < 1 = decrease sound
Syntax time FadeSound volume
PlaySound = plays a sound
Syntax PlaySound "soundfilename"

I've found INIT fields of units to be unreliable for anything except music. Triggers and waypoint are excellent places to use these commands..
Scripts work fairly well. Just keep it simple. And remember to use pauses so the action doesn't leave before the speaker has finished :).
Wav2Lip only works on wav files, not ogg. So you remember not to delete the base wav file, if you are going to use it.

OK last thing :)
BIS / Codemasters has released the Wav2Lip file, which creates lip synching files. You use these when you have the point-of-view on a unit as it speaks, to get the units lips to move.

Here's a list of files for you to play with.
Sample Mission
Egg Drop Wav-to-Ogg Converter
Wav2Lip


Hangfyre.