# Shooting problem

**URL:** <https://forum.kirupa.com/t/shooting-problem/213090>\
**Category:** Uncategorized\
**Created:** [January 16, 2007, 9:37pm UTC](https://forum.kirupa.com/t/shooting-problem/213090 "2007-01-16T21:37:58Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mario\_hater](https://avatars.discourse-cdn.com/v4/letter/m/e0b2c6/32.png) [@mario\_hater](https://forum.kirupa.com/u/mario_hater)\
**Post date:** [January 16, 2007, 9:37pm UTC](https://forum.kirupa.com/t/shooting-problem/213090/1 "2007-01-16T21:37:58Z")

</div>

I’ve tried 3 ways of doing this and i still keep getting the same result. Is there a way to shoot a bullet from the mouse using the attachMovie? I have got this code, but everytime you click, the previous bullet stops moving.

```auto
bullets = new Array();
i = 0;
onMouseDown = function () {
    i++;
    bullets* = attachMovie("bullet", "bullet"+i, i);
    bullets*._x = _xmouse;
    bullets*._y = _ymouse;
};
onEnterFrame = function () {
    bullets*._y -= 10;
};

```

can anyone point me in the right direction or suggest a tutorial or anything?
