Showing posts with label Animation. Show all posts
Showing posts with label Animation. Show all posts

Monday, November 15, 2010

Saturday, November 13, 2010

Bezier Tween in ActionScript 3

Flex Builder 4 Flash Video Flash Video

TweenMax also introduces an innovative feature called "bezierThrough" that allows you to define points through which you want the bezier curve to travel. Use the code below and alter the bezierThrough values, adding more or less values.

import gs.TweenMax;
import fl.motion.easing.*
TweenMax.to(mc, 3, {x:344, y:351, bezierThrough:[{x:78.2, y:198.15}, {x:260.05, y:93.75}, {x:348.8, y:123.3}], ease:Bounce.easeOut});

Click on the ball to start the tween


  • x:344, y:351 (The tween x & y values)
  • x:78.2, y:198.15 (1st Bezier point)
  • x:260.05, y:93.75 (2nd Bezier point)
  • x:348.8, y:123.3 (3rd Bezier point)

Wednesday, November 3, 2010

Timing Animation With ActionScript 3

Flex Builder 4 Flash Video Flash Video

Tween 2 Movie Clips without using the Timeline

Start a tween, and while it is playing start another one using the Timer Class and TimerEvent. First you have to import the classes, then create the timer. the Timer() constructor takes two parameters. The first parameter controls how frequently the TimerEvent.TIMER event gets dispatched (in milliseconds). The second parameter is the number of times that the TimerEvent.TIMER event will be dispatched before stopping.

import fl.transitions.Tween;
import fl.transitions.easing.*;
import flash.utils.Timer;
import flash.events.TimerEvent;
var timer:Timer = new Timer(1500, 1);//Creating the timer
timer.addEventListener(TimerEvent.TIMER, nextTween);
timer.start();

var myTweenX:Tween = new Tween(movieClip, "alpha", None.easeOut, 0, 1, 3, true);

function nextTween(e:TimerEvent):void{
var myTweenAlpha:Tween = new Tween(movieClip, "x", Strong.easeOut, 0, 300, 3, true);
timer.removeEventListener(TimerEvent.TIMER, nextTween);
}

ActionScript 3.0 Language Reference

Monday, November 1, 2010

Free Flash Extension: MotionSketch

Flex Builder 4 Flash Video Flex Builder 4

MotionBrush: Free Actionscript Class

motion sketch

Here's a comprehensive, sortable list of more Flash Extensions from ajarproductions

Related Posts Plugin for WordPress, Blogger...