Welcome To Snipplr
Everyone's Recent ActionScript 3 Snippets
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
Replace "-" with anything you want to. Useful for amending URLs.
0
1201
posted 13 years ago by gromitski
Simple usage:
var xmlLoader:LoadXMLUtil = new LoadXMLUtil("path_to_xml.xml");
xmlLoader.addEventListener(Event.COMPLETE, onLoaderComplete);
private function onLoaderComplete(event:Event):void{
trace("Loaded XML: ");
trace(xmlLoader.xml...
2
770
posted 13 years ago by burnandbass
This function will keep an image that is larger than the stage dragging within the stage view, stopping at any edge of the image.
0
693
posted 13 years ago by CammoKing
Quite trivial but can be needed sometimes. At least I know where to look when i'll forget it
1
805
posted 13 years ago by gandreini
Full credit for this goes to Deva Raj (@nsdevaraj). This is also a good function for doing a similar thing, http://snipplr.com/view/27954/as3-convert-a-number-to-a-string/
2
1176
posted 13 years ago by adrianparr
ActionScript 3
AS3 ColorUtil Class (inc. RGBtoCMYK, CMYKtoRGB, subtractive colour & addative colour)
Full credit for this class goes to Deva Raj (@nsdevaraj). Many thanks.
1
1051
posted 13 years ago by adrianparr
Adobe AIR offers an ability to save small snippets of data locally (eg. users' settings). Works also on Android. EncryptedLocalStore is stored encrypted using AES-CBC 128-bit method. It is not recommended to store more than 10 MB of data because of r...
0
756
posted 13 years ago by MaRmAR
Full credit for this code goes to Scratchbrain (http://www.scratchbrain.net/blog/ver2/)
0
805
posted 13 years ago by adrianparr
Very simple and basic TextHandle class, extends TextField... You can extend to fit your needs.
Basic usage:
var a:TextHandle = new TextHandle("some text");
addChild(a)
Optional params:
_size: uint ( default 22 ) - size of the textfiled...
1
865
posted 13 years ago by burnandbass
Listen to the Navigation keys and save their values in local Booleans
2
868
posted 13 years ago by JaaQ