Categories
Flash

5 Cool Flash Tricks

These are some of my favorite tricks Ive learned throughout the years in flash. Granted Ive never had a use for some of them and others only kinda half work. Nonetheless i think they’re pretty cool do here it goes.

1)Right Click:

this.onEnterFrame = function(){
if (ASnative(800, 2)(1)){
/// Right click has been executed
}
}

So this is cool and everything however there is no guarantee future flash versions will support this because ASnative() is undocumented. However I have found this code useful if I was ever trying to detect whether the left mouse button is being held down. Just change the 1 to a 2. Oh and if you change it to a 4 it detect middle click…. whoda thunk.

2) Smoke effect:
This ones kinda easy. There is this method: Realistic Fog/Smoke Effect
Basically i just use versions of that method minus the use of flash’s built in blur filter. It’s alot easier to just use a PNG thats alpha’d down to like 33% and have a couple of those moving over each other. This is what i got: http://www.lawjik.net/bishop/smoke.html

3) Transparent Background:

OK this one is kinda cool:
http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_14201

Ive never found a use for this but Ive def seen plenty of ads made like this. Im pretty sure not all browsers support this one tho so it might not be the best thing in the world to use. I think Kirupa.com goes into more detail about it somewhere.

4) AMFPHP:
This is prob my favorite. This makes flash remoting so easy. All you have to do is learn how to write up Object Oriented PHP scripts and flash can work with them instantly. I’ve used this for working with databases mostly, MySQL, but also for e-mail scripts, and other random functions. Best part is that its fast, and getting faster. The original developer gave up on it for personal reasons but its following has taken over and it continues to grow.
Check it out: http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_14201

5) SWFObject:
Ya I know i said coolest tricks IN flash but, come on, this is awesome. Its even better when u mix it with SWFAddress. Check it out. Basically swfobject gets rid of that whole “click to activate object” thing. It also lets you perform browser testing and the flash version. Swfaddress is just as cool. It makes it so your flash movie works with the back, forward, and refresh buttons on the browser.

So there it is. My favorites. I know some aren’t as useful as others but oh well they’re cool.

Leave a Reply

Your email address will not be published. Required fields are marked *