Help with music file
Author |
Message |
bahamut
|
Posted: Mon Jan 10, 2005 10:41 pm Post subject: Help with music file |
|
|
Im new to this so... yeah ok. When i make turing play a music file it goes throught the whole file and then does other tasks. Is there a way to make it run in the background? While other tasks are bieng preformed? |
|
|
|
|
|
Sponsor Sponsor
|
|
|
Delos
|
Posted: Mon Jan 10, 2005 11:10 pm Post subject: (No subject) |
|
|
Hello.
2 options.
First off, there's the good ol' process approach that we all find utterly irritating except in very particular situations.
Turing: |
var musicFileName : string := "mymusic.wav"
process playMe
Music.PlayFile (musicFileName )
end playMe
fork playMe
for i : 1.. 100
put "The music is now playing. Look sharp!"
delay (10)
end for
|
Then, there's the nicer version, that is only available in OOT 4.0.5 (AFAIK), and goes something like this.
Turing: |
var musicFileName : string := "mymusic.wav"
Music.PlayFileReturn (musicFileName )
for i : 1.. 100
put "Play on...flatten us with your volume!"
delay (10)
end for
|
Yes, I know the [syntax] tags aren't working yet for OOT, just getting into the habit...
Edit:
BTW, bahamut...resize your avtar or face the wrath of the many mods that shall be lurking quite soon...just a friendly warning... |
|
|
|
|
|
bahamut
|
Posted: Tue Jan 11, 2005 6:42 pm Post subject: thanks |
|
|
Thanks for the help i got it to work. |
|
|
|
|
|
|
|