From: rafa on
Hello everyone:
I am trying to get the playhead to wait for the sound on channel 1 to stop
playing, after sound in channel 1 is done, go to marker "main"

I wrote this on the framescript:

on exitFrame me
if sound(1).play = 0 then
go to "main"
end if
end

it gives me an error that reads "frame not defined"
Any ideas what am I doing wrong? I need the playhead to loop until sound on
channel 1 is done playing the go to the marker.

Thank you!



From: Mike Blaustein on
Do you have a frame labeled "main"? Apparently, Director does not think
you do... if you don't have one, then make one... if you do have one,
then make sure there are no spaces or anything else in the label
(perhaps delete the label and recreate it fresh)
From: rafa on
No luck Mike, I redid the marker. It just doesn't like it. When I compile the lingo, it doesn't give me any errors, until the play head gets to that point in the time line.
From: Mike Blaustein on
Try changing the code like this - it will wait until the sound is done,
then go to the NEXT frame. See if that works...

on exitFrame me
if sound(1).play = 0 then
go to the frame +1
end if
end
From: wherold on
Your wrong in sytax.

sound(x).play() is a method for playing sound.

use sound(x).isBusy() and it will work.

e.g.
on exitframe
if (sound(1).isBusy()) then
go to the frame
else
go to "main"
end if
end

regards
Wolfgang




 |  Next  |  Last
Pages: 1 2
Prev: Shockwave Player + Vista
Next: Icon in Tree Component