Schedule next play

  • Nevermind. I had it looking in the wrong folder for the music. Schedule next play defaults to the sound folder, not the music folder. Something I didn't anticipate. And, apparently music has to be playing for it to schedule a next play.

    Before I submit a bug report, it appears that schedule next play isn't working for music. The code sample below works perfect until I add the schedule next play. The basic logic is, if the music has ended, check an array of songs available and pick one at random, except for the song last played, delay it to give some silence and then play it.

    + Audio: On "Background" ended
    + System: [X] Is Muted
    ----+ System: While
    --------+ System: MusicRandom = MusicLastPlayed
    ---------> System: Set MusicRandom to round(random(0,MusicSongCount-1))
    --------+ System: Else
    ---------> Audio: Schedule next play for Audio.CurrentTime+(random(MusicMinDelay,MusicMaxDelay))
    ---------> Audio: Play MusicList.At(0,MusicRandom) not looping from Music at 0 dB (tag "Background")
    ---------> System: Set MusicLastPlayed to MusicRandom
    ---------> System: Stop loop
    

    I wanted to make sure I'm doing this correctly before complaining.

    There was a mention of this in a previous post back in Feb. but I'm guessing no bug report was filed.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)