# Need Some Help with attachMovie

**URL:** <https://forum.kirupa.com/t/need-some-help-with-attachmovie/318782>\
**Category:** flash\
**Created:** [January 30, 2011, 9:46am UTC](https://forum.kirupa.com/t/need-some-help-with-attachmovie/318782 "2011-01-30T09:46:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kentus](https://avatars.discourse-cdn.com/v4/letter/k/9dc877/32.png) [@Kentus](https://forum.kirupa.com/u/Kentus)\
**Post date:** [January 30, 2011, 9:46am UTC](https://forum.kirupa.com/t/need-some-help-with-attachmovie/318782/1 "2011-01-30T09:46:12Z")

</div>

I try to make an old shooter game and i have this problem:  
This is the code in Flash Cs3 AS2:  
if(Key.isDown(Key.SPACE)){  
{i++;  
if(pozition==“right”){  
\_root.attachMovie(“glont”,“glont”+i,\_root.getNextHighestDepth());  
\_root[“glont”+i].\_x=tank\_1.\_x+3;  
\_root[“glont”+i].\_y=tank\_1.\_y;  
}  
if(pozition==“left”){\_root.attachMovie(“leftBullet”,“leftBullet”+i,\_root.getNextHighestDepth());  
\_root[“leftBullet”+i].\_x=tank\_1.\_x-3;  
\_root[“leftBullet”+i].\_y=tank\_1.\_y;}  
if(pozition==“up”){  
\_root.attachMovie(“upBullet”,“upBullet”+i,\_root.getNextHighestDepth());  
\_root[“upBullet”+i].\_x=tank\_1.\_x;  
\_root[“upBullet”+i].\_y=tank\_1.\_y-3;  
}  
if(pozition==“down”){  
\_root.attachMovie(“downBullet”,“downBullet”+i,\_root.getNextHighestDepth());  
\_root[“downBullet”+i].\_x=tank\_1.\_x;  
\_root[“downBullet”+i].\_y=tank\_1.\_y+3;  
}  
The problem is when i hold space… i need a delay time between attachMovie load next mc because create a long image with my bullet.  
[http://89.41.129.47/tank/tank.html](http://89.41.129.47/tank/tank.html)  
for preview.
