PDA

View Full Version : how to create animation like pixelranger


srosales
01-09-2005, 03:54 PM
Hello everyone,

Pixelranger and 2advanced (who pixelranger works for), use a technique of creating and looping animations that I can't figure out. For example, if you go to pixelranger.com and then click on 'Genesis Project', you'll see a picture of a forest in the background. Every few seconds you'll see a bird fly by in the background. Its very subtle but effective. I can't figure out how he makes this animation loop, yet look so random. Can anyone help?

Thanks,

Sal

cobo
01-11-2005, 02:43 PM
hi,

create a mc with a little animation inside. put a stop(); on frame one.
on your last frame write:


stop();
myNumbers = 5; //to define max. Sec. to five
mySeconds = Math.round(random(myNumbers)); //choose one value randomly

myInterval = setInterval(startover, mySeconds);

function startover() {
gotoAndPlay(2);
clearInterval(myInterval);
}


I havenīt tested it but it should work something like that...

cobo