Posts filed under 'Flash'

Animation & Your Web site

The use of animation can make your website outstanding or ridiculous. Let’s focus on the outstanding. Your website might be the only contact or the initial contact of your perspective clients and visitors. You better make an impact, a positive impact.

What is my call to action? What the heck am I supposed to do? A website that immediately urges the user to the action you desire them to take is going to stand out from the rest. Quality animation can help you with user-friendly interactivity that keeps them coming back.

Humans naturally recognize differences and amplify attention to those changes in their environment. Animation is an asset when used to bring a logo to life, even briefly, and when adding a bit of sparkle to improve the clarity of an active button.

Here is a link ( http://www.ted.com/index.php/talks/hans_rosling_shows_the_best_stats_you_ve_ever_seen.html )

Hans Rosling in California on statistics and using animation to make an impact of his presentation and speech. Go to minute 4:00 to see the animation being used.

Add comment August 18th, 2008

Flash & Mobile Devices

tp://www.adobe.com/devnet/devices/articles/ten_tips_flash_lite_games.html

In the code example below, the _y property of the duplicated movie clip is extracting hard-coded values from an array. In contrast, the _x property is determined programmatically, by first calculating the width of the stage, and then placing the duplicate movie clips based on the resulting values of the calculation.

var clipNum = 3
var xLocate = Stage.width/ (clipNum+1);
var yArray = new Array (30,40,50);
for(x=1; x<=clipNum; x++){
var tempMc = attachMovie("block",
"block"+x, x);
with (tempMc) {
_x = xLocate*x;
_y = yArray[x-1];
}
}

http://www.adobe.com/devnet/devices/articles/flash_projects.html

People will access your project on different mediums and devices. They may even use a stylus or their finger to press buttons. Users will expect standard key presses will be used and followed. (Become familiar with common mobile device conventions.)

The options for functionality should be flexible and not device dependent. The general practice of keeping the functionality of your project separate from the events that trigger it will allow more compatibility and possibility of your project to operate on many different devices.

As you begin your project you should with a commonly used screen size (176×208 or even 240×320 pixels). These will allow you to port your game to devices much easier.

Your project files should be able to meet the needs of different displays. Perhaps allowing for resizing or rescaling the graphics and text will allow for greater display needs. Think about text size and legibility as well as graphics and bitmaps.

http://www.adobe.com/devnet/devices/articles/total_training_key_press_events.html

It’s important for the user to interact with the device and the application. You will use a broadcaster-listener model and handler method to allow the application to respond when the user has interacted with the device.

http://livedocs.adobe.com/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00002449.html

http://www.adobe.com/devnet/flash/articles/actionscript_guide_06.html

Use of variables should be utilized to help keep your code flexible. All of us have coded for “hitTest” functions now. Considering mobile devices, The method below is easy on the mobile processor and uses the objects x and y values as well as the objects dimensions.

var obj = new Object (x1, y1, w1, h1, x2, y2, w2, h2);
if((obj.x1 >= obj.x2) && (obj.x1+obj.w1 <=
obj.x2+obj.w2) && (obj.y1 >= obj.y2) && (obj.y1+obj.h1 <=
obj.y2+obj.h2)){
collision = true;
}else{
collision = false;
}

This code checks the relationship of obj.x1’s left edge in relation to obj.x2’s left edge. Next it evaluates the right edge, top edge and finally the bottom edge of both.

Add comment July 14th, 2008

ActionScript – SharedObject;

There are many possible uses of shared-objects. For example to keep track of a shopping cart (store a name and selections and values or clear all values); track a name and high score; to store user’s preferences; to check whether a user is a new visitor; or a remote shared-object; which allows you to save to and retrieve data from a Flash COM (RMTP) server.

I will post about two remote shared-object uses (from livedocs.adobe.com):

* Store and share data on Flash Media Server. A shared object can store data on the server for other clients to retrieve. For example, call SharedObject.getRemote() to create a remote shared object, such as a phone list, that is persistent on the server. Whenever a client makes changes to the shared object, the revised data is available to all clients currently connected to the object or who later connect to it. If the object is also persistent locally, and a client changes data while not connected to the server, the data is copied to the remote shared object the next time the client connects to the object.

* Share data in real time. A shared object can share data among multiple clients in real time. For example, you can open a remote shared object that stores a list of users connected to a chat room that is visible to all clients connected to the object. When a user enters or leaves the chat room, the object is updated and all clients that are connected to the object see the revised list of chat room users.

reference: http://flash-communications.net/technotes/sharedObjectEditor/index.html

http://flash-communications.net/technotes/sharedObjectEditor/editor.html

http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/net/SharedObject.html

http://www.kirupa.com/developer/actionscript/shared_objects.htm

Add comment June 25th, 2008

Develop time functions with Flash ActionScript 2.0

Discuss two ways that you can develop timing in Flash. What are the advantages to each?

Using the native onEnterFrame() or setInterval() functions are two ways to develop timing.

The onEnterFrame() executes as fast as your Frames per Second.

The following example I made a movie clip and named it mc with alpha set to 0:

mc.onEnterFrame = function()
{
if(mc._alpha < 100) {

mc._alpha += mc._alpha+1;
}

else
{
delete this.onEnterFrame;
trace("done");
}

}

/*  OUTPUT  **************************

mc alpha's in from alpha = 0 to alpha = 100

************************************ */

ActionScript 2.0 allows custom behaviors for movie clips that previously one would need to code into the "onMovieClip(enterFrame) handler. Therefore, you can have multiple movieclips with different characteristics but still exhibit similar behavior. The onEnterFrame method can be used to calculate the positions of a movie clip instance.

The setInterval() runs a function at a specified interval (in milliseconds) and can be modified to execute it's timing in any second or fraction thereof. (3.0 uses the "Timer" class instead of setInterval.) The setInterval() function allow you to set your own time-based event, similar to onEnterFrame(), executing repetively over time. And, setInterval returns object instead of interval id for better OOP structure.

The following example calls the "executeCallback" function every 3000 milliseconds (every 3 seconds).

var intervalId:Number;
var count:Number = 0;
var maxCount:Number = 10;
var duration:Number = 3000;

function executeCallback():Void {
trace("executeCallback intervalId: " + intervalId + " count: " + count);

if(count >= maxCount) {
clearInterval(intervalId);
}
count++;
}

intervalId = setInterval(this, "executeCallback", duration);

/*  OUTPUT  **************************

executeCallback intervalId: 1 count: 0

executeCallback intervalId: 1 count: 1
executeCallback intervalId: 1 count: 2
executeCallback intervalId: 1 count: 3
executeCallback intervalId: 1 count: 4
executeCallback intervalId: 1 count: 5
executeCallback intervalId: 1 count: 6

executeCallback intervalId: 1 count: 7
executeCallback intervalId: 1 count: 8
executeCallback intervalId: 1 count: 9
executeCallback intervalId: 1 count: 10

************************************ */

** References **

http://livedocs.adobe.com/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00002490.html
http://livedocs.adobe.com/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00001766.html
http://www.adobe.com/devnet/flash/articles/mc_subclasses_v2_03.html
http://www.actionscript.org/forums/archive/index.php3/t-95283.html


Add comment June 17th, 2008

Flash Tutorial

here are the videos with links to the downloads…

4/9/2007 “Introduction to Cartooning with Flash” Preview In this cartoon, we have a ringing phone, and in order to make the cartoon more interesting, we’re going to animate the phone receiver bouncing around on the cradle. In this video, Craig will show you how.

Phone Ringing Video

4/13/2007 “Introduction to Cartooning with Flash” Preview In this video, We’ll continue the walk cycle by creating a few more extreme positions, or keyframes.

http://newsletter.learnflash.com/t?ctl=1659804:A806D44AD0854AC4256195D9975B99DD81140A4E81E74E85

4/16/2007 Text Blur In this tutorial, you will learn to animate a custom text loop. This is a popular effect, and after this tutorial you will feel comfortable adding to text and graphics. http://newsletter.learnflash.com/t?ctl=1659809:A806D44AD0854AC4256195D9975B99DD81140A4E81E74E85

4/20/2007 Onion Skin Create a frame by frame animation using the onion skin option. Easily see what you sketched in the last frame and keep your animation consistent.

http://newsletter.learnflash.com/t?ctl=1659808:A806D44AD0854AC4256195D9975B99DD81140A4E81E74E85

4/23/2007 Motion Guide In this tutorial, you will learn how to animate a graphic on a guided path using the motion guide. You will also learn how to place your graphic or movieclip on the correct points of the motion guide.

http://newsletter.learnflash.com/t?ctl=1659807:A806D44AD0854AC4256195D9975B99DD81140A4E81E74E85

4/27/2007 Looping Banner A simple looping banner is an effective way to show scrolling buttons and add content to your site. Create a looping banner the easy way that is simple to edit.

http://newsletter.learnflash.com/t?ctl=1659806:A806D44AD0854AC4256195D9975B99DD81140A4E81E74E85

Also, in case you missed the announcement, here is your special link for a steep discount on all our training videos. This sale is for a very limited time so grab your copy while you can. http://newsletter.learnflash.com/t?ctl=1659803:A806D44AD0854AC4256195D9975B99DD81140A4E81E74E85

Hope you enjoy the videos.

Add comment April 26th, 2007


Calendar

March 2010
M T W T F S S
« Nov    
1234567
891011121314
15161718192021
22232425262728
293031  

Posts by Month

Posts by Category