Hi,
Can someone tell what’s wrong with this code? It won’t draw towards the right instead stops after moving 6px, as if the onEnterFrame event has been deleted. The criteria for deleting it is not filled though. I am pretty sure nothing else in the swf is interfering. (There isn’t much there yet) Here is the code:[AS]createEmptyMovieClip(“line1”, 1);
line1._x = Stage.width-381;
line1._y = Stage.height+18;
line1.lineStyle(3, 0xFF0000, 100);
line1.markerX = 0;
line1.markerY = 0;
line1.onEnterFrame = function() {
if (_root.ring11.beam1MC._alpha>99&&line1.markerX==0&&line1.markerY>=-102) {
line1.markerY -= 6;
line1.lineTo(line1.markerX, line1.markerY);
if (line1.markerX<=340 && line1.markerY<=-102) {
trace("markerY "+line1.markerY);
line1.markerX+=6;
line1.lineTo(this.markerX, this.markerY);
trace("markerX "+this.markerX);
if (line1.markerX>=720 && line1.markerY<=-102) {
trace(“this”);
delete this.onEnterFrame;
}
}
}
};[/AS]It might be something I am blind to but I have tried so many different things that I don’ know what to do anymore… :puzzled: