5.7. Creating 3D Buttons

Problem

You want to animate 3D buttons in Swift for use in Flash.

Solution

Import Swift-created buttons into the Flash authoring environment and control with ActionScript.

Discussion

The Swift 3D workflow involved for creating interactive elements, such as buttons for navigation, is occasionally confusing for new users, as the program itself has no scripting capabilities. Animations created in Swift 3D are strictly linear, playing from the first to the last frame; however, that all can change once imported into Flash, where content can be manipulated like any other imported asset.

This section covers two methods for creating buttons from Swift 3D graphics. The first uses a simple button symbol and bitmap data. The second uses a movie clip symbol and vector data.

Obviously the first things needed are some button graphics, which I have already created. I will be using the same source file for each example—you may download the T3D from http://www.rightactionscript.com/fcb/chpt5/button.zip; however, I suggest going through the following steps and previously discussed techniques to create your own, in order to experience the process from start to finish.

Taking the button concept quite literally, I modeled the nice, shiny, red, cartoony button shown in Figure 5-33. It is just waiting for someone to come along and push it! But before someone can do that, we need to get it out of Swift 3D and into Flash where a little interaction can be added.

When adding materials and ...

Get Flash 8 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.