Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help Changing music mid level
FlawlessHappiness Offline
Posting Freak

Posts: 3,980
Threads: 145
Joined: Mar 2012
Reputation: 171
#3
RE: Changing music mid level

What you use is:

void PlayMusic(string& asMusicFile, bool abLoop, float afVolume, float afFadeTime, int alPrio, bool abResume);

Plays music.asMusicFile - the music to play + extension .ogg
abLoop - determines whether a music track should loop
afVolume - volume of the music
afFadeTime - time in seconds until music reaches full volume
alPrio - priority of the music. Note that only the music with the highest priority can be heard! 0 - lowest, 1 - higher, etc.
abResume - if true, playback will be continued from where the track stopped after the call to StopMusic(); if false, the track will be restarted.


And

void StopMusic(float afFadeTime, int alPrio);

Stops music.afFadeTime - time in seconds until music stops
alPrio - the priority of the music that should stop

Trying is the first step to success.
(This post was last modified: 02-11-2013, 07:51 AM by FlawlessHappiness.)
02-11-2013, 07:51 AM
Find


Messages In This Thread
Changing music mid level - by serbusfish - 02-10-2013, 05:07 PM
RE: Changing music mid level - by serbusfish - 02-11-2013, 01:08 AM
RE: Changing music mid level - by FlawlessHappiness - 02-11-2013, 07:51 AM



Users browsing this thread: 1 Guest(s)