Factorio Prototype DocsVersion 1.1.107

AmbientSound - 'ambient-sound' Example code

This prototype is used to make sound while playing the game. This includes the game's music, composed by Daniel James Taylor.

Properties

type :: "ambient-sound"

Specification of the type of the prototype.

Specification of the type of the prototype.

name :: string

Unique textual identification of the prototype.

Unique textual identification of the prototype.

sound :: Sound

The sound file and volume.

The sound file and volume.

track_type :: union

Lets the game know in what instances the audio file is played.

Lets the game know in what instances the audio file is played.

weight optional :: double

Properties

type :: "ambient-sound"

Specification of the type of the prototype.

name :: string

Unique textual identification of the prototype.

sound :: Sound

The sound file and volume.

track_type :: union

Lets the game know in what instances the audio file is played.

Union members

"menu-track"

This track is only played in the main menu.

"main-track"

This track is played interleaved (alternating) with "interlude" tracks.

"early-game"

This track is considered a main track, with no functional difference to "main-track".

"late-game"

This track is considered a main track, with no functional difference to "main-track".

"interlude"

This track is played in between the main tracks.

weight :: double optional

Default: 1

Example

{
  type = "ambient-sound",
  name = "world-ambience-4",
  track_type = "interlude",
  sound =
  {
    filename = "__base__/sound/ambient/world-ambience-4.ogg",
    volume = 1.2
  }
}

Prototypes

Types