Package pilas :: Module pytweener :: Class Tweener
[hide private]
[frames] | no frames]

Class Tweener

source code

object --+
         |
        Tweener

Instance Methods [hide private]
 
__init__(self, duration=0.5, tween=None)
Tweener This class manages all active tweens, and provides a factory for creating and spawning tween motions.
source code
 
hasTweens(self) source code
 
addTweenNoArgs(self, obj, function, initial_value, value, **kwargs)
Similar a addTween, solo que se especifica la funcion y el valor de forma explicita.
source code
tweenObject or False
addTween(object, **kwargs)
Example: tweener.addTween( myRocket, throttle=50, setThrust=400, tweenTime=5.0, tweenType=tweener.OUT_QUAD )
source code
 
removeTween(self, tweenObj) source code
 
getTweensAffectingObject(self, obj)
Get a list of all tweens acting on the specified object Useful for manipulating tweens on the fly
source code
 
removeTweeningFrom(self, obj)
Stop tweening an object, without completing the motion or firing the completeFunction
source code
 
removeTweeningFromObjectField(self, obj, field)
Stop tweening an object, without completing the motion or firing the completeFunction
source code
 
finish(self) source code
 
update(self, timeSinceLastFrame) source code
 
eliminar_todas(self) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, duration=0.5, tween=None)
(Constructor)

source code 

Tweener This class manages all active tweens, and provides a factory for creating and spawning tween motions.

Overrides: object.__init__

addTween(object, **kwargs)

source code 

Example: tweener.addTween( myRocket, throttle=50, setThrust=400, tweenTime=5.0, tweenType=tweener.OUT_QUAD )

You must first specify an object, and at least one property or function with a corresponding change value. The tween will throw an error if you specify an attribute the object does not possess. Also the data types of the change and the initial value of the tweened item must match. If you specify a 'set' -type function, the tweener will attempt to get the starting value by call the corresponding 'get' function on the object. If you specify a property, the tweener will read the current state as the starting value. You add both functions and property changes to the same tween.

in addition to any properties you specify on the object, these keywords do additional setup of the tween.

tweenTime = the duration of the motion tweenType = one of the predefined tweening equations or your own function onCompleteFunction = specify a function to call on completion of the tween onUpdateFunction = specify a function to call every time the tween updates tweenDelay = specify a delay before starting.

Returns: tweenObject or False