-
AS2 :: Guestbook Class
Goal: To devise an easy way to add user interaction to a full-Flash site, in this case a guestbook.
class org.thesourcecode.utils.Guestbook { private var _earl:String; private var _display; private var _getEntries:LoadVars; private var _sender:LoadVars; private var _receiver:LoadVars; private var _refresh:LoadVars; private var _mainTL:MovieClip; private var _validname:Boolean; private var _validemail:Boolean; private var _validcity:Boolean; private var _validmsg:Boolean; private var _array:Array; private var _uri:String; public function Guestbook( target:MovieClip ) { _mainTL = target; }//end constructor //retreive the specified posts public function getPosts( url:String, target, min:Number, max:Number ) { _earl = url; _display = target; _getEntries = new LoadVars(); _getEntries.onLoad = function( success:Boolean ) { if (success) { target.text = this.strflash; } else { target.text = this.strflash; } } _getEntries.load(_earl); } //get the user-entered info and insert intoREAD MORE
-
AS2 :: BackgroundFill Class
Goal: To devise an easy reusable way to create seamless backgrounds for full-screen Flash movies whether it be gradients or bitmaps. Works with a “bg” Object customized to your needs.
import flash.display.BitmapData; import flash.geom.Matrix; class org.thesourcecode.utils.BackgroundFill { private var _main:MovieClip; private var _sub:MovieClip; private var _w:Number; private var _h:Number; private var _gradient:Object; private var _bitmap:String; private var _fillType:String; private var _colors:Array; private var _alphas:Array; private var _ratios:Array; private var _matrix:Matrix; private var _tile:BitmapData; public function BackgroundFill( clip:MovieClip ) { _main = clip; }//end constructor public function fillBg( bg:Object ):Void { _w = Stage.width; _h = Stage.height; _bitmap = bg.bitmap; _gradient =READ MORE
-
flashextensibility dot com back online!!
Peter Elst has relaunched this really cool site and already has some nice tools available. If you use the Flash IDE for development you owe it to yourself to get into JSFL by either taking advantage of the extensions others create or creating your own littleREAD MORE
-
The Document Class
Adobe has stepped it up a level with the next release of Flash Professional. In AS 2, the general line of thought was “1-frame SWFs with all ActionScript on its own layer”. I even followed that pattern myself for the past year or so. But,READ MORE
-
JSFL :: ExportImage
Here’s a useful command that will take all the bitmaps in your library and export them as PNGs to a directory of your choosing. This shortcut was made a lot easier thanks to the new exportPNG() method introduced in Flash 8.
/* * JSFL ExportImage * Author:READ MORE -
New Classes
Caught the urge the other day to finish up some classes I had started on a while ago. During the wrap up I got a Java-Doc inspiration. The result (4) nifty little classes with complete documentation that simplify everyday life in Flash. I present XMLMenu,READ MORE
-
Guestbook Reloaded and Revolutions
Some folks were still in need after viewing Flash Guestbook Basics so I’ve added (2) more videos. Part 2 covers building the PHP script that handles the Flash to MySQL communication while Part 3 deals solely with getting the MySQL database setup. Hopefully this willREAD MORE
Posts tagged as "Flash"