home *** CD-ROM | disk | FTP | other *** search
/ 600 Games / 600games.iso / Aventura / freaky-fun.swf / scripts / DefineSprite_310 / frame_1 / DoAction.as
Encoding:
Text File  |  2006-06-07  |  442 b   |  29 lines

  1. n = -1;
  2. n1 = 1;
  3. this.onEnterFrame = function()
  4. {
  5.    var _loc1_ = _root;
  6.    moving._x += n;
  7.    count++;
  8.    if(count == 200)
  9.    {
  10.       count = 0;
  11.       n = - n;
  12.    }
  13.    if(moving.hitTest(_loc1_.hero))
  14.    {
  15.       _loc1_.hero._x += n;
  16.    }
  17.    moving1._x += n1;
  18.    count1++;
  19.    if(count1 == 120)
  20.    {
  21.       count1 = 0;
  22.       n1 = - n1;
  23.    }
  24.    if(moving1.hitTest(_loc1_.hero))
  25.    {
  26.       _loc1_.hero._x += n1;
  27.    }
  28. };
  29.