【发布时间】:2017-11-13 18:56:42
【问题描述】:
我有这个功能
function generateCircles2(){
for(var i = 1; i<500; i++){
var position = Math.floor(Math.random() * 600);
var size = Math.floor(Math.random() * 8);
var circle = paper.circle(-50,position,size);
var time = Math.floor(Math.random() * 4000) + 2000;
circle.attr("fill", "#000000");
var cirAni = Raphael.animate({cy: position, cx: 850}, time);
circle.animate(cirAni.delay(100));
}
}
假设生成圆圈以在屏幕上随机点移动,但是圆圈不会出现,并且它还会阻止其他动画在这些动画的顶部发生。如何让这些圆圈随机移动,同时保持其他动画同时进行?
【问题讨论】:
标签: javascript animation raphael