View unanswered posts | View active topics It is currently Mon Dec 30, 2024 10:19 pm



Reply to topic  [ 4 posts ] 
 Temporarily replace overworld music? 
Author Message
User avatar

Joined: Sat Jun 19, 2010 5:02 pm
Posts: 331
Location: Mekkan
Reply with quote
Post Temporarily replace overworld music?
I'd like to know how to temporarily replace the overworld music with some other sound, whether it be silence or music or something else. Not in mission lua, in the lua of an item. I know this is possible but not how to do it. So... How do I do it? Thanks!


Fri Aug 05, 2011 11:01 pm
Profile
User avatar

Joined: Tue Jun 12, 2007 11:52 pm
Posts: 13144
Location: Here
Reply with quote
Post Re: Temporarily replace overworld music?
Code:
   AudioMan:ClearMusicQueue();
   AudioMan:PlayMusic("Base.rte/Music/Watts/Last Man.ogg", -1, -1);

The first function stops the music currently playing I believe.

I don't remember what the last 2 arguments for the second function mean. One is probably how many times to loop the music (-1 for infinite).


Fri Aug 05, 2011 11:15 pm
Profile
User avatar

Joined: Sat Jun 19, 2010 5:02 pm
Posts: 331
Location: Mekkan
Reply with quote
Post Re: Temporarily replace overworld music?
Is there a way to make the old music play again after the sound finishes? Oh and by the way, the second argument is how many times to loop.


Fri Aug 05, 2011 11:18 pm
Profile

Joined: Sat Feb 03, 2007 7:11 pm
Posts: 1496
Reply with quote
Post Re: Temporarily replace overworld music?
The first one is how many times to loop, the second one is the volume.

I believe that QueueMusicStream is the function you are looking for.

http://wiki.datarealms.com/index.php/Lu ... dioManager


Sun Aug 07, 2011 5:36 pm
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 4 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.032s | 13 Queries | GZIP : Off ]