I’m using a code to make the same music play in all scenes
However, the music doesn’t loop once it ends/ how can I correct this?
1. * extends AudioStreamPlayer
2. * const level_music = preload("res://Sounds/Cozmo_Title.wav")
3. * func _play_music(music: AudioStream, volume = 0.0):
4. * if stream == music:
5. * return
6. *
7. * stream = music
8. * volume_db = volume
9. * play()
10. *
11. * func play_music_level():
12. * _play_music(level_music)