# Sound playing twice

**URL:** <https://forum.kirupa.com/t/sound-playing-twice/50690>\
**Category:** Uncategorized\
**Created:** [May 5, 2004, 3:33pm UTC](https://forum.kirupa.com/t/sound-playing-twice/50690 "2004-05-05T15:33:27Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dru\_nasty](https://avatars.discourse-cdn.com/v4/letter/d/90db22/32.png) [@dru\_nasty](https://forum.kirupa.com/u/dru_nasty)\
**Post date:** [May 5, 2004, 3:33pm UTC](https://forum.kirupa.com/t/sound-playing-twice/50690/1 "2004-05-05T15:33:27Z")

</div>

Okay, I have some music (a short loop) that begins playing when my movie is loaded. The movie is 4 frames. Frame 1 & 2 consist of the preloader. Frame 3 has only my music on it. Frame 4 has the script to attachSound.

attachSound.track = new Sound();  
track.attachSound(“soundtrack”);  
track.start(0,99);

I also have a stop and play button on the stage to control the music.  
They work fine, but if I press play while the music is going through its first loop only, it starts up again and i get overlapping.Anytime after that its fine. Weird.  
Heres whats on the play button;

on(press) {  
if (playing != true) {  
\_root.track.start(0,99);  
playing = true;  
}  
}

Any takers?
