home *** CD-ROM | disk | FTP | other *** search
/ 600 Games / 600games.iso / Acao / midnightstrike1.swf / scripts / DefineSprite_60 / frame_1 / DoAction.as
Encoding:
Text File  |  2007-04-02  |  523 b   |  16 lines

  1. this.age = 0;
  2. this.onEnterFrame = function()
  3. {
  4.    if(int(this.age) < 10)
  5.    {
  6.       this.age = int(this.age) + 1;
  7.    }
  8.    this._x = (Math.random() - 0.5) * this.age * 3;
  9.    this._y = (Math.random() - 0.5) * this.age * 3;
  10.    var _loc2_ = Math.random() * 5 * this.age + 40;
  11.    _loc2_ -= Math.max(0,this.age - 8) * 10;
  12.    this._xscale = this._yscale = _loc2_;
  13.    this.gotoAndStop(int(Math.min(this._totalframes,Math.max(2,int(Math.random() * 5) + this.age * 2.7))));
  14.    this._rotation = Math.random() * 360;
  15. };
  16.