Skip to main content
Known Participant
January 10, 2013
Answered

Lower background music while video is playing

  • January 10, 2013
  • 1 reply
  • 2577 views

Hello,

I have created a flash website using AS3 and I want my background music to to soften while a video is playing and pick back up again when someone clicks to go to another page. Any suggestions?

Thank you

This topic has been closed for replies.
Correct answer kglad

then use:

var st:SoundTransform=this.transform.soundTransform;

st.volume=.2;

this.transform.soundTransform=st;


my error.  use:

var st:SoundTransform=this.soundTransform;

st.volume=.2;

this.soundTransform=st;

1 reply

kglad
Community Expert
Community Expert
January 10, 2013

use your sound's soundchannel soundtransform property or your movieclip's soundtransform property.

if you don't understand the above, do you create your sound using actionscript or using a timeline?

Known Participant
January 10, 2013

Using a timeline.

Known Participant
January 11, 2013

what timeline contains your sound?

to what timeline did you add the code?

copy and paste the code you used.


It is all in the same timeline there is a layer for actions and a layer for the music separately. I copy and pasted the same code you posted above. I tried changing mc to the music file name and then the frame label but it didn't work.