...actually i tried this code on the frame:
currentslotnum = 1;stop ();function addToslot (item) { if (!item.found) { item._x = eval("itemSlot"+currentslotnum)._x; item._y = eval("itemSlot"+currentslotnum)._y; item.found = true; currentslotnum++; }}
var bc=1000;
_root.onMouseDown=function(){
bc++;
if(bc>1100){ bc=1000; }
duplicateMovieClip("bullet","bullet","bull
et")
}
this one on the gun:
onClipEvent (mouseMove) {
Xd =_root._xmouse-_x;
Yd =_root._ymouse-_y;
radAngle = Math.atan2(Yd, Xd);
_rotation = int((radAngle*360 / (2*Math.PI))+0);
updateAfterEvent();
}
and this one on the bullet:
onClipEvent(load){
spd=20;
_x=_root.gun._x;
_y=_root.gun._y;
_rotation= _root.gun._rotation;
}
onClipEvent(enterFrame){
if(_name == "bullet"){
_x = -1000;
}else{
if (_rotation>180) {
_y += (spd*Math.cos( Math.PI/180*_rotation));
_x -= (spd*Math.sin( Math.PI/180*_rotation));
} else {
_y -= (spd*Math.cos (Math.PI/180*_rotation));
_x += (spd*Math.sin( Math.PI/180*_rotation));
}
if(_x>Stage.width || _x<0 || _y<0 || _y>Stage.height){
this.removeMovieClip();
}
}
because i tried every script i could find and it didnt work.