Game Maker Studio’ audio engine is based on the .ogg format, sounds can be uploaded in .wav or .mp3, but if chosen to they can be compressed to .ogg to optimize memory usage.
The audio functions we will be using for this game are:
“This function returns whether a sound exists (true) or not (false). Note that if the index you search for has not been initialised previously, this function will cause an error as it is searching for non-existent asset indices. The sound to check can either be a single instance of a sound (the index for individual sounds being played can be stored in a variable when using the audio_play_sound or audio_play_sound_at functions) or a sound asset.”
audio_play_sound(index, priority, loop);
“With this function you can play any sound resource in your game. You provide the sound index and assign it a priority, which is then used to determine how sounds are dealt with when the number of sounds playing is over the limit set by the function audio_channel_num.”