In case Flash no longer exists; a copy of this site is included in the Flashpoint archive's "ultimate" collection.

Dead Code Preservation :: Archived AS3 works from wonderfl.net

真面目な、ぐにゃぐにゃ線

画面をクリックで左から、ぐにゃぐにゃの線が
上下きっりに動きながら右に進みます。

http://wonderfl.net/c/zdLqは「不真面目Ver」です。
Get Adobe Flash player
by yuugurenote 22 Aug 2011
    Embed
/**
 * Copyright yuugurenote ( http://wonderfl.net/user/yuugurenote )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/7tG7
 */

package {
    import flash.display.Sprite;
    import flash.display.Graphics;
    import flash.display.Bitmap;
    import flash.display.BitmapData;
    import flash.events.MouseEvent;
    import flash.events.Event;
    import flash.geom.ColorTransform;
     [SWF(width=465,height=465,backgroundColor=0xFFFFFF,frameRate=60)]

    public class AS110822_01 extends Sprite {
        public var sw:Number=stage.stageWidth;
        public var sh:Number=stage.stageHeight;
        public var myColor:ColorTransform = new ColorTransform();
        public var myColor2:Number;
        public var viewBmd:BitmapData=new BitmapData(sw,sh,false,0x000000);
        public var viewBmp:Bitmap=new Bitmap(viewBmd);
        public var _mySprite:mySprite;
        public var _mySprite2:mySprite2;
        public var px:Number=0;
        public var py:Number;
        public var py2:Number;

        public function AS110822_01() {

            addChild(viewBmp);
            var tmpBmd:BitmapData;
            myColor.redMultiplier=0.999;
            myColor.greenMultiplier=0.999;
            myColor.blueMultiplier=0.999;
            addEventListener(Event.ENTER_FRAME,xDraw);
            stage.addEventListener(MouseEvent.MOUSE_DOWN,xDown);
        }
        public function xDraw(e:Event):void {
            viewBmd.draw(stage,null,myColor);
        }
        public function xDown(e:MouseEvent):void {
            
            myColor2 = Math.random() * 0xFFFFFF;
            
            _mySprite = new mySprite(myColor2);
            _mySprite.x=px;
            py=mouseY;
            _mySprite.y=py;
            addChild(_mySprite);

            _mySprite2 = new mySprite2(myColor2);
            _mySprite2.x=px;
            py2=mouseY-60;
            _mySprite2.y=py2;
            addChild(_mySprite2);

        }
    }
}

import flash.display.Sprite;
import flash.geom.ColorTransform;
import flash.events.Event;
import flash.events.MouseEvent;
import flash.filters.BlurFilter;

class mySprite extends Sprite {

    public var deg:Number=0;
    public var myFil:BlurFilter=new BlurFilter(4,4,2);

    public function mySprite(myColor2:Number) {

        this.graphics.beginFill(myColor2,1);
        this.graphics.drawCircle(0,0,3);
        this.graphics.endFill();

        this.filters=[myFil];
        this.addEventListener(Event.ENTER_FRAME,xEnter);
    }

    public function xEnter(e:Event):void {
        deg = (deg+10)%360;
        this.y=this.y-5*Math.sin(deg*Math.PI/180);
        this.x+=2;

        if (this.x>stage.stageWidth) {
            this.removeEventListener(Event.ENTER_FRAME,xEnter);
            this.graphics.clear();
        }
    }
}

class mySprite2 extends Sprite {

    public var deg:Number=0;
    public var myFil:BlurFilter=new BlurFilter(4,4,2);

    public function mySprite2(myColor2:Number) {

        this.graphics.beginFill(myColor2,1);
        this.graphics.drawCircle(0,0,3);
        this.graphics.endFill();

        this.filters=[myFil];
        this.addEventListener(Event.ENTER_FRAME,xEnter);
    }

    public function xEnter(e:Event):void {
        deg = (deg+10)%360;
        this.y=this.y-5*Math.sin(- deg*Math.PI/180);
        this.x+=2;

        if (this.x>stage.stageWidth) {
            this.removeEventListener(Event.ENTER_FRAME,xEnter);
            this.graphics.clear();
        }
    }
}