A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: [F8] load external swf with sound

Hybrid View

  1. #1
    Senior Member
    Join Date
    Nov 2004
    Posts
    286

    [F8] load external swf with sound

    I have a site im making, and created the site sounds/music in a seperate swf.

    I wanted to know how do I load this into my site in the first frame, and then have it play looped without restarting should someone go back to the first frame? (you know so the sound doesnt play again over whats playing already)

  2. #2
    FK'n_dog a_modified_dog's Avatar
    Join Date
    Apr 2003
    Location
    "aaarf"
    Posts
    9,176
    Code:
    // external movie-
    _global.sndtrk = new Sound(this);
    sndtrk.attachSound("my_trk");
    sndtrk.start(0, 999); // seconds offset, loops
    
    // main movie
    function init(){
    if(!running){
    loadMovieNum("external.swf" 1000);
    running = true;
    }
    };
    
    init();
    very similiar to code i posted to your other thread

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