Product Review: SWF Protector – taterboy
July 18th, 2010 | Filed under: Flash, Flex, Reviews



Get 25% off of SWF Protector by using the coupon code: REFLPRTCT-RTW5

Though we try to encourage openness and sharing here at taterboy.com, there are some swf files that have to be protected. SWF Protector, by DECOMSOFT, is a very simple application for securing your code and assets within an SWF. The procedure could not be easier, just load the swf you want to protect, then click the “Protect” button. SWF Protector uses some kind of protection and obfuscation to secure your SWF files; Advanced Mode gives you control over how much protection and obfuscation is applied to each file.

In testing SWF Protector we used two actionScript 3 games, one built in Flash (a few thousand of lines of code with embedded graphics and sounds), the other built in Flex( light on code and graphics). With the Flex game the process was just as described above, a couple clicks and the swf was protected. In the case of the Flash game, I had to turn off obfuscation in one part of the swf to get a secured version to play all the way through without error. Once each game was protected and verified, the latest decompiler was not match for them. All the code, graphics and game resources were safe and sound. As a test, I ran a decompiler on the unprotected versions of the games and they were both rendered back into source code, cold and exposed.

There are a few swf protection applications out there, some with very advanced features. SWF Protector is the simplest way to protect your SWF files at a fraction of the price.

SWF Protector
Developer: DCOMSOFT
Platform: Windows, Mac, Linux
Price: Business License: $59.95

Get 25% off of SWF Protector by using the coupon code: REFLPRTCT-RTW5

Technorati Tags: , , , , ,

| No Comments »

Intro to MVC Part 1: The Controller Class – taterboy
July 13th, 2010 | Filed under: ActionScript 3, Flash, Flex, Games, Tutorials

About a year ago, @devgirl, introduced me to the MVC framework and provided me with a stubbed out demo of everything working together. There were many more class files than I was used to, one for data and variables (Model), one for all the graphic elements and UI controls (View), and one to control all the information between the two (Controller). My brain hurt for a couple weeks as I attempted to absorb what seemed like magic and how to apply it to a new job that was about to start. This process has changed the way I approach every project, even simple tasks with only a few lines of code. On smaller projects I may only leverage one part of the MVC framework and figured this was the best way to introduce it to others without it being so overwhelming. So today, I what to present the Controller class, which is part of the MVC framework.



Read More »

Technorati Tags: , , , , , , , , , , ,

| 1 Comment »

How to Build an Engaging Preloader in Flash – taterboy
June 30th, 2010 | Filed under: ActionScript 3, Design, Flash, Flex, Tutorials


Get Adobe Flash player


The Importance of a Good Preloader:
Everyone hates to wait, especially for websites to load. The only thing keeping a potential user sitting in their chair and staring at the screen, while your application loads, is the hope that eventually something great will happen. If that user is impatient, like most of us, the preloader may be the only opportunity you have to interact with a potential user/customer. The fact that something is moving on screen reassures users that your website has not locked up their computer. We may not think that a few seconds is a long time, but to the waiting user, it may seem like minutes. We should take advantage of this brief moment to make a good impression, give them a taste of what’s to come and develop trust.

Read More »

Technorati Tags: , , , ,

| 1 Comment »

Jump Back in TIme with HTML5 – taterboy
June 19th, 2010 | Filed under: Design, Flash

UPDATE 6/23/10

Google released a great new HTML5 resource HTML5 Rocks for those looking to learn more about HTML5, complete with samples and tutorials. Some of the coolest stuff (animation, transitions) is webkit based, it will be interesting to see how IE 9 handles this. Chrome Frame is an interesting concept for dealing with IE until IE 9 is released, kind of like an HTML5 plugin for IE 6, 7 and 8. I wonder if it will work with IE 9 to enable webkit supported HTML5 features?

I’ve been trying to work on new Flash and Flex tutorials, but keep getting sucked back into the HTML5 vs Flash debate. There are so many new quotes that reinforce that fact that a world without Flash is just not what the future holds in store. HTML5 and Flash a Reality Check

As an enthusiastic Mac fan for over 2 decades, I agreed 100% with Apple when they announced the end of the floppy drive. Steve Jobs has some good arguments for saying that the end of Flash is near, but all the logic put forth to support this claim does not seem to be supported by reality. Flash does have it’s faults, but so do all technologies we work with everyday. Plus, Apple’s track record on picking all the right technologies has not been without error, it did take them over twenty years to add a second button to their mouse.
Read More »

Technorati Tags: , , , , , , , ,

| 12 Comments »

Building Custom Loaders in Flex – taterboy
June 5th, 2010 | Filed under: ActionScript 3, Animation, Flash, Flex, Tutorials

In an earlier post I talked all about building Flex UI components with Flash. This example shows how to create a custom loader component, in Flash or Flex, and use it to replace the standard Flex progress bar.


Get Adobe Flash player




The Base Preloader:
I found a preloader class online that implemented the IPreloaderDisplay, this is required to build a custom preloader. You can find out more about building your own here. I took the class I found online and made it generic so I could use it as a base class for all my future preloaders.
Read More »

Technorati Tags: , , , , , , , ,

| 2 Comments »

A Microphone And A Baby - Flash AS3 Microphone Class – taterboy
May 21st, 2010 | Filed under: ActionScript 3, Audio, Flex, Tips

Here is a little demo from some recent playing with Flash’s Microphone class.



Real demo is below the fold.

This is basically a microphone level meter that my son and I thought was pretty fun. Don’t wake the baby.
Read More »

Technorati Tags: , , , , , ,

| 2 Comments »

Flash vs. HTML5 – taterboy
May 3rd, 2010 | Filed under: Flash, iPhone

Does It Have To Be One Or The Other?
I have never been a “use Flash because I like Flash”, kind-of guy. I do like Flash, but believe very strongly that we should only use Flash when there is a good reason to use Flash opposed to other available technologies. I’m very proficient in javascript and have always tried to see how far I can push other technologies into the realm of what I currently use Flash for. I have built HTML driven sites that have many of the same fancy roll-over effects, fading and non-reloading, immersive approaches that make them look like Flash sites. I have been building these type of sites as early as 2006, before many of the web standards we have today. I do not use Flash because I lack web skills, but where current non-Flash technologies fall short. These decisions are based on the needs of the each project, end-user, development time, SEO, etc. I will be an adopter of HTML5 and currently use many of the non-Flash technologies when needed. I can not see me adopting HTML5 as a one or the other sort of thing, it will be whatever the needs of the job require. I foresee, going forward, there will be many HTML5/Flash hybrid sites, just like there are now many HTML/Flash hybrid sites.

If HTML5 truly is a competitor of Flash, that is a good thing. It will only encourage better performing, feature-rich options in Flash going forward. This notion of HTML5 being a Flash killer, just is not true, at least for a long time.

Taking the Test:
There are some online HTML5 browser tests you can use to test compatibility. Until all of the major browsers (IE) fully adopt this standard, it is not a viable option for most web development needs. Even Safari is not fully complitent with the HTML5 standard according to this test. I got 115 out of 160 with Safari 4.0.5 and 113 out of 160 on my iPhone, with some of the most important UI support still not supported.

Here is a great video, sent by Greg Wilson, that puts the HTML5 vs. Flash in perspective for now.

Technorati Tags: , , , , , ,

| 1 Comment »

Flash CS5 to iPhone? Not So Fast – taterboy
April 25th, 2010 | Filed under: Flash, iPhone

Updated Below

Just days before the official announcement of Adobe’s suite of CS5 applications, Apple Inc, updated their iPhone Developer Agreement with a few lines like, “Applications must be originally written in Objective-C, C, C++…” and “Applications that link to Documented APIs through an intermediary translation or compatibility layer or tool are prohibited”. The web was abuzz with what all this meant for Adobe and other third party tools that make developing for Apple’s iPhone more accessible. It was speculated that this was a clear shot from Apple Inc, across the bow of S.S. Adobe Systems, Inc. It might as well have been a headline that read, “Safari Dropping Flash Player In a Push for HTML5”.

On April 15, 2010, Adobe forged ahead and introduced Flash CS5 and all of its iPhone app building potential. Were they disoriented from the blast still ringing in their ears, or did they know something the rest of us didn’t?

As we internally discussed the repercussions of the Apple Development Agreement update and what it meant for our future on the iPhone/iPad platform, we contemplated the words “originally written in …”. Perhaps this was not as bad as it sounded. We are, after all, users and fans of Apple products and are very concerned by the thought of this great company becoming that grouchy old man in the neighborhood that just put up a huge warning sign stating “If You Are Not an Objective-C programmer, You Shall Not Pass!”
Read More »

Technorati Tags: , , , , ,

| 2 Comments »

Combining Flash Visual Components with Flex Classes – taterboy
March 30th, 2010 | Filed under: ActionScript 3, Flash, Flex, Tutorials

Building Visual Flex Components using Flash swc Shared Libraries.

I love building skins or visual components in Flash and doing all my coding in Flex. I also try to make all the code as component-ized as possible, so that it can be reused in future projects. So I have visual component classes from Flash and functionality classes built in Flex. How do we marry the two without hardcoding the flash asset names into your Flex code?

The Approach:
Build as little functionality in Flash as possible and establish templates for how each component should be structured. Here are a couple processes for getting those Flash visual components hooked up to your Flex code.

Method1 - The Direct Approach:
In your code that is specific to your application, create all your visual instances first then pass them in as properties to your class.

There is a Flash visual component called “NewButton”

?View Code ACTIONSCRITP
//create the visual instance
var btn:NewButton = new NewButton();
 
//create the functionality class instance
var btnCode:NewButtonClass = new NewButtonClass(btn);
addChild(btnCode);

Inside the NewButtonClass class the “btn” instance is used as an Object, the functionality is attached to the visual object and everything is added to the stage.

?View Code ACTIONSCRIPT
private var baseBtn:Object;
public function NewButtonClass(obj:Object):void{
	baseBtn = obj;
 
	// attach listeners
 
	addChild(baseBtn);
 
}

Depending on the class and needs, sometimes it is best to pass in an Array of visual object instances.
Read More »

Technorati Tags: , , , , ,

| 1 Comment »

Flash Player 10 3D settings with AS3/Flex – taterboy
March 9th, 2010 | Filed under: ActionScript 3, Flash, Flex, Tutorials

Flash Player 10’s 3D capabilities are pretty light, but they have opened up many possibilities in UI design. Getting the perspective just right will take some tweaks, so here’s a demo to show some of the inner workings, like focal length and field of view.

Using the PerspectiveProjection class is the key to getting 3D in Flash looking just right, it is also very easy to use.

?View Code ACTIONSCRIPT
//new PerspectiveProjection
var pers:PerspectiveProjection = new PerspectiveProjection();
 
//set the field of view - doesn't really do much
pers.fieldOfView = 55;//Default: 55, Range: 1 - 180
 
//set the focal length
pers.focalLength = 663;//Default: 663
 
//get stage center for a straight view, if you want a straight view.				
var centerX:Number = stage.stageWidth * 0.5;
var centerY:Number = stage.stageHeight * 0.5;
 
//set the projection center
pers.projectionCenter = new Point(centerX, centerY);
 
//assign to root/stage
//root.transform.perspectiveProjection = pers;
 
//assign to target/DisplayObject
triImage.transform.perspectiveProjection = pers;

See demo below.
Read More »

Technorati Tags: , , , , , , ,

| No Comments »