[Golist] cycles design continued...

Cedric M. analogdesign newsl at analogdesign.ch
Tue Mar 25 00:55:33 PDT 2008


Hi,
 
Excellent, I haven't tested it yet but it sounds clean and expandable:
from the top of my head:
easingOnCycle
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html#easingOnCycle>  may be a list of easings to
play randomly for example if easingOnCycleBehaviour is equal to Repeater
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html#easingOnCycle> .RANDOM:
for example for a shining star, you may have five type of shining Tweens
giving it a more natural life, than using the same easing back and forth.
Every time a cycle is finished it jumps to another Tween.
This option may be interesting for secondary animated elements to add depth
to the main animation.
Of course it may bring confusion, but it is and advanced feature... So would
it be acceptable?
By the way it is something that I've used in some past Fuse-projects with a
home made implementation, so it sounds that it is something usable, at least
to me ;), it would be very useful to put it into Goasap ;)
 
Let me know what do you think about it...
 
Best regards.

Cedric M. (aka maddec)

Interactive Creative
Adobe Flash/Flex/AIR Specialist 
Since 1998
----------------------------------------------------
 <http://analogdesign.ch/> http://analogdesign.ch
 <http://analogdesign.ch/blog> http://analogdesign.ch/blog
visual & interactive communication
----------------------------------------------------

 


  _____  

De : golist-bounces at goasap.org [mailto:golist-bounces at goasap.org] De la part
de Moses Gunesch
Envoyé : lundi, 24. mars 2008 21:08
À : Mailing list for the Go ActionScript Animation Platform
Objet : Re: [Golist] cycles design continued...


Okay here's what I've cooked up: 
A couple of simple iterator utils that sit in the managers package, Repeater
& LinearGoRepeater.

This has allowed me to condense the cycles feature of LinearGo quite a
bit... the class no longer contains properties cycles, easeOnCycle or the
two properties that were still needed, extra easing params for easeOnCycle
and an option to play the tween multiple times forwards instead of cycling
back-and-forth. All of that has been neatly encapsulated so you can now do,

mytween.repeater.cycles = 2;
mytween.repeater.reverseOnCycle = false; // play fwd both times


Let me know what you think of this implementation, the release including
useFrames is pretty much ready now.

-moses

Class Repeater

Constant	Defined by	
 	 	INFINITE
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/Repeater.html#INFINITE>  : uint = 0 

[static] Makes code more human-readable, like new
Repeater(Repeater.INFINITE);
Repeater	


 	Property	Defined by	
 	 	currentCycle
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/Repeater.html#currentCycle>  : uint 

[read-only] Current cycle starting at 0, which will continue to increase up
to cycles or indefinitely if cycles is set to Repeater.INFINITE (zero).
Repeater	
 	 	cycles
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/Repeater.html#cycles>  : uint 

Number of times the Repeater will iterate, which can be set to zero or
Repeater.INFINITE for indefinite repeating.
Repeater	
 	 	done
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/Repeater.html#done>  : Boolean 

[read-only] True if cycles is not infinite and currentCycle has reached
cycles.
Repeater	


Class LinearGoRepeater


 	  	 direction
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html#direction>  : int 

[read-only] Current play direction depending on reverseOnCycle and
currentCycle.
LinearGoRepeater	
 	  	 easingOnCycle
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html#easingOnCycle>  : Function 

Storage for optional secondary easing to use on reverse cycles.
LinearGoRepeater	
 	  	 extraEasingParams
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html#extraEasingParams>  : Array 

Additional parameters to use with easingOnCycle if the function accepts more
than four.
LinearGoRepeater	
 	  	 reverseOnCycle
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html#reverseOnCycle>  : Boolean 

Whether tween direction should reverse every other cycle.
LinearGoRepeater	
Class LinearGo



LinearGo
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/it
ems/LinearGo.html#LinearGo()> (delay:Number, 
duration:Number, 
easing:Function = null, 
extraEasingParams:Array = null, 
repeater:
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html> LinearGoRepeater = null, // new!
useRelative:Boolean = false, 
useRounding:Boolean = false, 
useFrames:Boolean = false, // new!
pulseInterval:Number)

repeater
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/it
ems/LinearGo.html#repeater>  : LinearGoRepeater
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/LinearGoRepeater.html>  

[read-only] A LinearGoRepeater instance that defines options for repeated or
back-and-forth cycling animation.
Class SequenceBase



repeater
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ut
ils/SequenceBase.html#repeater>  : Repeater
<file:///Users/moses/Data/Eclipse_Workspace/Go/Go_Current/docs/org/goasap/ma
nagers/Repeater.html>  

[read-only] The sequence's Repeater instance, which may be used to make the
sequence loop and play more than one time.
SequenceBase	
(replaces repeatCount & currentCount properties for Sequence & SequenceCA)



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://goasap.org/pipermail/golist_goasap.org/attachments/20080325/e773c263/attachment.html 


More information about the GoList mailing list