julzmon
03-29-2003, 03:30 AM
I have this script in a frame. The point of this is to move and rotate these blocks a second or two after the first one moves. Then I have a similar script with different coordinates in another frame. The problem is when i go to another frame with the different coordinates the squares twitch between the two coordinates. I can't seem to figure out how to cancel the setInterval.
Please help
block2move1 = function() {
block1.inside.Rotate(50, movingspeed);
block1.Move(500, 400, movingspeed);
}
block2move2 = function() {
block2.inside.Rotate(100, movingspeed);
block2.Move(500, 400, movingspeed);
}
block2move3 = function() {
block3.inside.Rotate(10, movingspeed);
block3.Move(450, 400, movingspeed);
}
block2move4 = function() {
block4.inside.Rotate(30, movingspeed);
block4.Move(400, 700, movingspeed);
}
setInterval(block2move1,1000);
setInterval(block2move2,2000);
setInterval(block2move3,3000);
setInterval(block2move4,4000);
updateAfterEvent()
Please help
block2move1 = function() {
block1.inside.Rotate(50, movingspeed);
block1.Move(500, 400, movingspeed);
}
block2move2 = function() {
block2.inside.Rotate(100, movingspeed);
block2.Move(500, 400, movingspeed);
}
block2move3 = function() {
block3.inside.Rotate(10, movingspeed);
block3.Move(450, 400, movingspeed);
}
block2move4 = function() {
block4.inside.Rotate(30, movingspeed);
block4.Move(400, 700, movingspeed);
}
setInterval(block2move1,1000);
setInterval(block2move2,2000);
setInterval(block2move3,3000);
setInterval(block2move4,4000);
updateAfterEvent()