Chaos Project

RPG Maker => General Discussion => Topic started by: Memor-X on January 11, 2012, 01:49:39 am

Title: Checking if BGM is finished
Post by: Memor-X on January 11, 2012, 01:49:39 am
i thought up a kick ass way to do some music while i was playing Fate/Stay Night, i break up the file into smaller segments that can be added at the end of each other in any order and sound seamless, the Rivy battle Music in Chaos Project be the best example of a song that could be done like this and it's one everyone would have heard

anyway, i am wondering if there is a way to check if a BGM is playing or if it's stopped, it will save a lot of work having to calculate just how many frames i should wait

this is the pseudo code i thought up


play segment 1
loop
    if bgm != playing
         num = random 1 - 5
         play segment num
    end
   
    if stopbgm == true
         break loop
    end
repeat


naturals i don't plan to replace all my music like this, just certain scenes like game over and the title screen

EDIT: it would also help if the method can be used in ARCed as well if that makes a difference
Title: Re: Checking if BGM is finished
Post by: Blizzard on January 11, 2012, 02:20:17 am
ARC won't support this in the very first release, but you can expect a quick update afterwards that will allow you to queue music tracks to be played like a "playlist" which will even be able to loop the playlist beginning from another track than the first one.

EDIT: In CP I did that through a sound effect SE played shortly before engaging into battle that then served as "intro" to the actual track.