var finished: SimpleSignalEmitted when the Tween has finished all tweening. Never emitted when the Tween is set to infinite looping (see setLoops(_:)).
var loopFinished: Signal2Emitted when a full loop is complete (see setLoops(_:)), providing the loop index. This signal is not emitted after the final loop, use [signal finished] instead for this case.
var stepFinished: Signal1Emitted when one step of the Tween is complete, providing the step index. One step is either a single Tweener or a group of Tweeners running in parallel.
func bindNode(Node?) -> Tween?Binds this Tween with the given node. Tweens are processed directly by the SceneTree, so they run independently of the animated nodes. When you bind a Node with the Tween, the Tween will halt the animation when the object is not inside tree and the Tween will be automatically killed when the bound object is freed. Also .tweenPauseBound will make the pausing behavior dependent on the bound node.
func chain() -> Tween?Used to chain two Tweeners after setParallel(_:) is called with true.
func customStep(delta: Double) -> BoolProcesses the Tween by the given delta value, in seconds. This is mostly useful for manual control when the Tween is paused. It can also be used to end the Tween animation immediately, by setting delta longer than the whole duration of the Tween animation.
func getLoopsLeft() -> Int32Returns the number of remaining loops for this Tween (see setLoops(_:)). A return value of -1 indicates an infinitely looping Tween, and a return value of 0 indicates that the Tween has already finished.
func getTotalElapsedTime() -> DoubleReturns the total time in seconds the Tween has been animating (i.e. the time since it started, not counting pauses etc.). The time is affected by setSpeedScale(speed:), and stop will reset it to 0.
func isRunning() -> BoolReturns whether the Tween is currently running, i.e. it wasn’t paused and it’s not finished.
func isValid() -> BoolReturns whether the Tween is valid. A valid Tween is a Tween contained by the scene tree (i.e. the array from getProcessedTweens will contain this Tween). A Tween might become invalid when it has finished tweening, is killed, or when created with Tween.new(). Invalid Tweens can’t have Tweeners appended.
func kill()Aborts all tweening operations and invalidates the Tween.
func parallel() -> Tween?Makes the next Tweener run parallelly to the previous one.
func pause()Pauses the tweening. The animation can be resumed by using play.
func play()Resumes a paused or stopped Tween.
func setEase(Tween.EaseType) -> Tween?Sets the default ease type for PropertyTweeners and MethodTweeners animated by this Tween.
func setLoops(Int32) -> Tween?Sets the number of times the tweening sequence will be repeated, i.e. set_loops(2) will run the animation twice.
func setParallel(Bool) -> Tween?If parallel is true, the Tweeners appended after this method will by default run simultaneously, as opposed to sequentially.
func setPauseMode(Tween.TweenPauseMode) -> Tween?Determines the behavior of the Tween when the SceneTree is paused. Check TweenPauseMode for options.
func setProcessMode(Tween.TweenProcessMode) -> Tween?Determines whether the Tween should run after process frames (see _process(delta:)) or physics frames (see _physicsProcess(delta:)).
func setSpeedScale(speed: Double) -> Tween?Scales the speed of tweening. This affects all Tweeners and their delays.
func setTrans(Tween.TransitionType) -> Tween?Sets the default transition type for PropertyTweeners and MethodTweeners animated by this Tween.
func stop()Stops the tweening and resets the Tween to its initial state. This will not remove any appended Tweeners.
func tweenCallback(Callable) -> CallbackTweener?Creates and appends a CallbackTweener. This method can be used to call an arbitrary method in any object. Use Callable/bind() to bind additional arguments for the call.
func tweenInterval(time: Double) -> IntervalTweener?Creates and appends an IntervalTweener. This method can be used to create delays in the tween animation, as an alternative to using the delay in other Tweeners, or when there’s no animation (in which case the Tween acts as a timer). time is the length of the interval, in seconds.
func tweenMethod(Callable, from: Variant, to: Variant, duration: Double) -> MethodTweener?Creates and appends a MethodTweener. This method is similar to a combination of tweenCallback(_:) and tweenProperty(object:property:finalVal:duration:). It calls a method over time with a tweened value provided as an argument. The value is tweened between from and to over the time specified by duration, in seconds. Use Callable/bind() to bind additional arguments for the call. You can use setEase(_:) and setTrans(_:) to tweak the easing and transition of the value or setDelay(_:) to delay the tweening.
func tweenProperty(object: Object?, property: NodePath, finalVal: Variant, duration: Double) -> PropertyTweener?Creates and appends a PropertyTweener. This method tweens a property of an object between an initial value and finalVal in a span of time equal to duration, in seconds. The initial value by default is the property’s value at the time the tweening of the PropertyTweener starts.