Wintermute Engine Forum
Wintermute Engine => Technical forum => Topic started by: Mikael on May 02, 2008, 05:10:58 PM
-
Which is the easiest way to loop two separate music files after one another (that is, alternating between them)?
Thanks,
Mikael
-
putting them as one file and looping it :D
Game.AttachScript("alternate_looper.script");
where the script file would look like something like this:
while(1)
{
Game.PlayMusic("some ogg file");
while (Game.IsMusicPlaying()) Sleep(500);
Game.PlayMusic("another ogg file");
while (Game.IsMusicPlaying()) Sleep(500);
}
-
putting them as one file and looping it ;D
I've done that one or two times in the past.
Thanks!
Mikael
-
of course by modifying my previous code you can make playlists as well. (but with 3 and more files I'd already choose some object logic how to add new files to the playlist etc.). How's good ole Carol Reed doing? ;)
-
Carol is doing fine, thank you. She's currently being translated to German, Japanese, and Russian, which, unexpectantly, has lead to some hard work for her. But she's had time to tell me all about her latest adventure, which is currently in the works.
Mikael