Flash中duplicateMovieClip的用法??
请问在Flash中【目标.duplicateMovieClip("新名称","深度")】和【duplicateMovieClip("目标","新名称","深度")】的区别...
请 问在Flash中【目标.duplicateMovieClip("新名称","深度")】和【duplicateMovieClip("目标","新名称","深度")】的区别。一直都觉得他们是没有区别的,但是下面代码的显示确不一样,求解释,谢谢。
一、var i = 1;
var newsnow;
_root.snow.onEnterFrame = function() {
newsnow = snow.duplicateMovieClip("newsnow"+i, i);
newsnow._x = random(550);
newsnow._y = random(400);
newsnow._xscale = random(80)+20;
newsnow._yscale = newsnow._xscale;
i++;
};
二、var i = 1;
var newsnow;
_root.snow.onEnterFrame = function() {
newsnow = duplicateMovieClip("snow","newsnow"+i, i);
newsnow._x = random(550);
newsnow._y = random(400);
newsnow._xscale = random(80)+20;
newsnow._yscale = newsnow._xscale;
i++;
}; 展开
一、var i = 1;
var newsnow;
_root.snow.onEnterFrame = function() {
newsnow = snow.duplicateMovieClip("newsnow"+i, i);
newsnow._x = random(550);
newsnow._y = random(400);
newsnow._xscale = random(80)+20;
newsnow._yscale = newsnow._xscale;
i++;
};
二、var i = 1;
var newsnow;
_root.snow.onEnterFrame = function() {
newsnow = duplicateMovieClip("snow","newsnow"+i, i);
newsnow._x = random(550);
newsnow._y = random(400);
newsnow._xscale = random(80)+20;
newsnow._yscale = newsnow._xscale;
i++;
}; 展开
2个回答
展开全部
flash版本为flash
mx
我的雨滴已经画好并做成影片剪辑元件名为“mc"
然后下面是我写在场景中的代码:
function
ee
()
{
duplicatemovieclip
("mc",c,c);
setproperty(c,_x,random(550));
setproperty(c,_y,random(-100));
updateafterevent();
c++;
if
(c>300){
clearinterval(kk);
}
}
c=1;
kk=setinterval(ee,20,20);
mx
我的雨滴已经画好并做成影片剪辑元件名为“mc"
然后下面是我写在场景中的代码:
function
ee
()
{
duplicatemovieclip
("mc",c,c);
setproperty(c,_x,random(550));
setproperty(c,_y,random(-100));
updateafterevent();
c++;
if
(c>300){
clearinterval(kk);
}
}
c=1;
kk=setinterval(ee,20,20);
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询