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

forked from: 意味が分からないw AS3

せっかくなのでProxyでやってみた
Get Adobe Flash player
by kaikoga 27 Nov 2009
/**
 * Copyright kaikoga ( http://wonderfl.net/user/kaikoga )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/6WQL
 */

// forked from nitoyon's 意味が分からないw AS3
// forked from 9re's forked from: 意味が分からないw
// forked from paq's 意味が分からないw
package {
    import flash.display.Sprite;
    //せっかくなのでProxyでやってみた
    public class FlashTest extends Sprite {
        public function FlashTest( ) {
            const _:uint = 0xcccccc;
            const P:uint = 0xff0000;
            const R:uint = 0xcccc00;
            const O:uint = 0x00ff00;
            const X:uint = 0x00cccc;
            const Y:uint = 0x0000ff;
            new Test(this.graphics, 21, 10, 10, 4)
            [_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_]
            [_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_]
            [_][P][P][_][_][R][R][_][_][_][O][_][_][X][_][X][_][Y][_][Y][_]
            [_][P][_][P][_][R][_][R][_][O][_][O][_][X][_][X][_][Y][_][Y][_]
            [_][P][_][P][_][R][_][R][_][O][_][O][_][X][_][X][_][Y][_][Y][_]
            [_][P][P][_][_][R][R][_][_][O][_][O][_][_][X][_][_][_][Y][_][_]
            [_][P][_][_][_][R][_][R][_][O][_][O][_][X][_][X][_][_][Y][_][_]
            [_][P][_][_][_][R][_][R][_][O][_][O][_][X][_][X][_][_][Y][_][_]
            [_][P][_][_][_][R][_][R][_][_][O][_][_][X][_][X][_][_][Y][_][_]
            [_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_]
            [_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_][_]
        }
        
    }
    
}

import flash.display.Graphics;
import flash.utils.Proxy;
import flash.utils.flash_proxy;

class Test extends Proxy {
    
    private var i:int = 0;
    private var graphics:Graphics;
    private var cols:int;
    private var width:int;
    private var height:int;
    private var margin:int;
    
    public function Test(graphics:Graphics, cols:int, width:int, height:int, margin:int) {
        this.graphics = graphics;
        this.cols = cols;
        this.width = width;
        this.height = height;
        this.margin = margin;
    }
    
    override flash_proxy function getProperty(name:*):* {
        graphics.beginFill(name);
        graphics.drawRect((i % cols) * (width + margin), Math.floor(i / cols) * (width + margin), width, height);
        graphics.endFill();
        i++;
        return this;
    }
    
}