Modpack UI icon

We need sounds that are copyrighted under the GNU GPL or a compatible license (eg public domain). If you want to add or modify freeciv sounds or you have an idea concerning freeciv sounds, feel free to email us or visit the Rulesets and modpacks forum.

How to exchange sounds[]

Some sounds are available with the "modpack installer" tool (freeciv-mp-*) shipped with Freeciv; other old sounds from the download server. If you want to contribute sounds, visit Freeciv's ticket tracker, create a new 'feature', and attach the files in WAV or OGG format.

Sound creators
Please name sound files intelligibly. Include a README where you present the licensing terms used (if public domain, say so) for the sound files.
Modpack makers
Please give secondary tags that refer to standard tags so that those who have not downloaded the latest & greatest sound pack can still enjoy the game.

Sound Support Overview[]

The server sends the client a list of primary and secondary sound tags for certain events. The primary tags are those preferred by the current modpack. The client does not need to have these sounds. The secondary tags should refer to standard sounds that all installations of Freeciv should have.

Tags are used to give an easy way to change sounds. A specfile is used to indicate which tags refer to which sound files. A change of spec file, given as an option at startup, will change sounds. For example,

 freeciv-gtk2 -S mysounds

will read sound files from mysounds.soundspec. To have a first glance into a soundspec file look at the data/stdsounds.soundspec file in Git. You will need to download, then copy or link those sounds into whichever directory is mentioned in this file first, or edit it to refer to the right files. All references are by default relative to the data/ directory. Soundpacks can be downloaded from the Freeciv website in the tar format. You will either need to unpack them with e.g. tar -xzvf stdsoundsX.tar.gz or use WinZip (for Windows), and put the files in the data directory mentioned above.


There are two kinds of sound tags:

  • defined in the rulesets
  • defined in the program code

While the former can be chosen freely the latter can't be changed.

The sound tags associated with improvements (wonders and normal buildings), unit movements and unit fights have to be set in the rulesets. Freeciv just hand these sound tags over to the client where they are translated into the filenames of the sound files via the soundspec file. Every soundspec should have generic sound tags for wonders (w_generic), normal buildings (b_generic), unit movements (m_generic) and unit fights (f_generic).

Sound tags associated with certain events are generated in the Freeciv code and can't be configured from outside. The soundspec file also has to have mapping for these tags. The complete list of such tags can be found in data/stdsounds.soundspec. The name of the tag is enum name (see common/events.h) in lowercase. So E_POLLUTION becomes the tag e_pollution. There is no generic event tag and no alternate tags are used.

There is currently only one music: the intro music. This music will be played until the game starts. The tag for this music is music_start.


The output of the sounds at the client side are done by plugins. The set of available plugins depend on the libraries found on the host system. You can choose the plugin the client should use via the command line:

freeciv-gtk2 --Plugin sdl

You can choose none to mute the client. Freeciv currently supports the following plugins:

Dummy plugin.
Plugin for SDL with SDL_mixer library.

To add support for a new plugin, change these files (where whatever is the name of the new plugin):			/* add new test */
 client/audio.c			/* link in new plugin */
 client/		/* add the files below */
 client/audio_whatever.c	/* audio plugin */
 client/audio_whatever.h	/* audio plugin's header */


There are a few things that can be done to get better sound support in Freeciv still:

  • add more plugins (gstreamer, arts, windows, etc)
  • add a sound tag for each technology, as for buildings/units
  • always add more event tags
  • find or create better sound samples and make better spec-file

See also[]

Game Anatomy & Modding
Event ScriptingEditing RulesetsEditing TilesetsMore RulesetsMore Tilesets