Another Fuse example:
import com.mosesSupposes.fuse.*;
ZigoEngine.register( Fuse, PennerEasing );
// build a short intro sequence to apply to box1_mc.
var f:Fuse = new Fuse();
f.label = "swoopyIntro";
f.target = box1_mc;
f.push({ delay: .25 });
// labels can be used in some methods but are mostly a convenience.
f.push({ label: "appear",
start_scale: 500,
start_alpha: 0,
time: 1.75,
ease: "easeOutBack",
trigger: .5 // advances this action early
});
// the array brackets in this action form a group of parallel tweens
f.push([
{ label: "swoop",
x: "80",
controlY: "50", // adds a bezier curve
time: 1.5,
ease: "easeInOutBack"
},
// these tweens bounce back, by using 2 cycles
{ brightOffset: 50,
rotation: 10,
ease: "easeInOutQuad",
cycles: 2,
time: .5,
delay: .25
}
]);
// a simple callback. You could also subscribe to the "onComplete" event.
f.push({ func:"trace", args:"done!" });
f.traceItems();
f.start(true); // passing true presets start props - remove it to see a change.
ZigoEngine.register( Fuse, PennerEasing );
// build a short intro sequence to apply to box1_mc.
var f:Fuse = new Fuse();
f.label = "swoopyIntro";
f.target = box1_mc;
f.push({ delay: .25 });
// labels can be used in some methods but are mostly a convenience.
f.push({ label: "appear",
start_scale: 500,
start_alpha: 0,
time: 1.75,
ease: "easeOutBack",
trigger: .5 // advances this action early
});
// the array brackets in this action form a group of parallel tweens
f.push([
{ label: "swoop",
x: "80",
controlY: "50", // adds a bezier curve
time: 1.5,
ease: "easeInOutBack"
},
// these tweens bounce back, by using 2 cycles
{ brightOffset: 50,
rotation: 10,
ease: "easeInOutQuad",
cycles: 2,
time: .5,
delay: .25
}
]);
// a simple callback. You could also subscribe to the "onComplete" event.
f.push({ func:"trace", args:"done!" });
f.traceItems();
f.start(true); // passing true presets start props - remove it to see a change.
0 Comments:
Post a Comment
Links to this post:
Create a Link
<< Home