A Flash Developer Resource Site

Results 1 to 7 of 7

Thread: Flash MX mp3 lopping!?!?!?

  1. #1
    Junior Member
    Join Date
    Jun 2001
    Posts
    11

    Arrow

    Hello Board!
    I´m trying to use some external mp3 files as background sounds to a flash site, but I can´t find any way to loop it.

    Can someone help me to get the sound to loop???

    Please help me, if you know the answer!!!

  2. #2
    Senior Member EQFlash's Avatar
    Join Date
    Jun 2002
    Location
    where i'm at
    Posts
    2,735
    variable.start(0,100) // where 100 is how many times it will loop

  3. #3
    Junior Member
    Join Date
    Jun 2001
    Posts
    11

    Arrow Realy this simple???

    Is it realy that simple???

    I´m using an external mp3-file as background sound!!!

  4. #4
    Senior Member EQFlash's Avatar
    Join Date
    Jun 2002
    Location
    where i'm at
    Posts
    2,735
    yes it's that simple

  5. #5
    Junior Member
    Join Date
    Jun 2001
    Posts
    11

    no it´s not!!!

    I don´t think it was realy that simple, I attach my code to let you see if I have made anythin wrong!!!

    Here is my code for playing the sound:
    function playMusic(song){
    MittLjud_sound.stop();
    MittLjud_sound=new Sound();
    MittLjud_sound.loadSound(song,true)
    MittLjud_sound.setVolume(MittLjud_sound.getVolume( ) -50);

    // supose to start the sound then loop it 100 times.
    MittLjud_sound.start(0,100);
    }

    playMusic("bg.mp3");

  6. #6
    Senior Member EQFlash's Avatar
    Join Date
    Jun 2002
    Location
    where i'm at
    Posts
    2,735
    rewrite the code like this;

    MittLjud_sound=new Sound();
    MittLjud_sound.loadSound("bg.mp3",true);
    MittLjud_sound.setVolume(50);
    MittLjud_sound.start(0,100);

  7. #7
    Junior Member
    Join Date
    Jun 2001
    Posts
    11

    OK!

    OK! Thanks!!!

    But am I able to chang the background sound from within my flash movie if I set ("bg.mp3",true);???

    Can I still change this from a button???

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center