audio_sound_get_track_position

This function gets the position (in seconds) within the sound file for the sound to play from.

The function can take a Sound Asset or a sound instance. It returns: 

 

Syntax:

audio_sound_get_track_position(index);

Argument Type Description
index Sound Instance ID or Sound Asset The sound asset or instance to get the play position of.

 

Returns:

Real

 

Example 1:

if audio_sound_get_track_position(global.Music) != 0
{
    audio_sound_set_track_position(global.Music, 0);
}

The above code checks a track to get its start position and if it's not 0 seconds it sets it to 0 seconds.