This is an experiment in using the new BitmapData.floodFill() method. This is a modification of the example that was posted over at protozoo. See the example below and then the actionscript below that.
[as]_root.createEmptyMovieClip(“con”,1);
con._x = man._x;
con._y = man._y;
var bitmapData = new flash.display.BitmapData(191,183,false);
con.attachBitmap(bitmapData,2);
bitmapData.draw(man);
man.onMouseDown = function() {
bitmapData.draw(man);
bitmapData.floodFill(this._xmouse,this._ymouse,c.color);
}[/as]
No comments:
Post a Comment