发新话题
打印

飘散调整

飘散调整

[这个贴子最后由ygsky在 2007/01/28 10:34pm 第 1 次编辑]

原来120*320  怎么样才能让飘散效果 1、调整到:550*400。2、如何能调到右边。

TOP

飘散调整

修改Mc的_x属性就可以了

TOP

飘散调整

怎么修改呢? ---------------------------- _root.ranspeed = 0.100000; movstyle = function () { if (this._x < 0) { this._x = 200; } else if (this._x > 200) { this._x = 0; } // end if if (this._y > 330) { this._y = -10; } // end if this._x = this._x + this.speedtype * _root.ranspeed; this._y = this._y + this.speedtype * 1.600000; }; for (i = 1; i <= 20; i++) { mc.duplicateMovieClip("m" + i, i); _root["m" + i].gotoAndPlay(Math.ceil(Math.random() * 180)); _root["m" + i]._x = Math.random() * 200; _root["m" + i]._y = Math.random() * 330; _root["m" + i]._alpha = i * 5 + 20; _root["m" + i]._xscale = i * 20; _root["m" + i]._yscale = i * 20; _root["m" + i].speedtype = i / 3; _root["m" + i].onEnterFrame = movstyle; } // end of for _root.onEnterFrame = function () { if (_root.timem >= 50) { _root.ranspeed = (Math.random() - 0.500000) * 0.800000; _root.timem = 0; } else { _root.timem++; } // end if };

TOP

飘散调整

   if (this._x < 0)
   {
       this._x = 200;
   }
   else if (this._x > 200)
   {
       this._x = 0;
   } // end if
   if (this._y > 330)
   {
       this._y = -10;
   } // end if

就是这个,200和330
x轴不能超过200
下落不超过330
改这二个值

TOP

飘散调整

[这个贴子最后由ygsky在 2007/01/29 10:38pm 第 1 次编辑]

谢谢 blueboyss 的帮助,这是550宽度右边飘飞的心叶

TOP

飘散调整

这个是宽度550飘飞的心叶

TOP

发新话题