API Reference › Audio › Audio.play_music
method

Audio.play_music

Audio.play_music(id) -> void

Plays the sound id as looping background music on the single music channel; any music already playing is stopped first.

Example

program Demo {
  entry {
    let theme = Audio.load("theme.ogg")
    Audio.play_music(theme)
  }
}
← All symbols