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


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
StrartMusic Work But not Stop
jessehmusic Offline
Senior Member

Posts: 423
Threads: 102
Joined: Dec 2011
Reputation: 8
#11
RE: StrartMusic Work But not Stop

(02-28-2012, 06:44 AM)Mackiiboy Wrote: 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, >0 - higher

void StopMusic(float afFadeTime, int alPrio);

Stops music.

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

So, all the pink stuff needs to be the same if you want to stop the music. I would either put StopMusic in OnLeave() in the current map, or in OnEnter() in the next map.

PlayMusic("Music_file_name.ogg", true, 1.0f, 0, 0, true);
StopMusic(0, 0);
Ah Thanx dude Smile Btw i fixed it Smile

http://www.moddb.com/mods/jessehmusic - Hospital of horror , WIP
02-28-2012, 03:17 PM
Website Find


Messages In This Thread
StrartMusic Work But not Stop - by jessehmusic - 02-27-2012, 06:59 PM
RE: StrartMusic Work But not Stop - by Mackiiboy - 02-28-2012, 06:44 AM
RE: StrartMusic Work But not Stop - by jessehmusic - 02-28-2012, 03:17 PM



Users browsing this thread: 1 Guest(s)