-- Defines constants and plays music and sound effects function init_sound() -- each name maps to a pattern number to play music_map = { desert = 0 } end -- call this once to initialize biome sound. -- by convention channel 4 should always be the -- preferred sfx channel, so we unmask it. function play_biome_music(biome) music(music_map[biome], 2000, 7) end