• Studio

  • Bots

  • Web API

  • Designer Resources

  • Host Resources

  • API

    Datatypes

    Edit

    Tween

    Tween object for creating smooth animations and transitions.

    Properties

    isPlaying

    boolean

    Indicates if the tween is currently playing.

    isPaused

    boolean

    Indicates if the tween is currently paused.

    isValid

    boolean

    Indicates if the tween is valid and can be used.

    time

    number

    Current time of the tween.

    Current time of the tween normalized to the range [0, 1].

    duration

    number

    Total duration of the tween.

    Checks if any tween is currently animating.

    Methods

    Plays the tween animation.

    Returns

    Stops the tween animation.

    Parameters

    executeCallbacks

    boolean

    Returns

    void

    Pauses the tween animation.

    Returns

    void

    Updates the tween animation for the given delta time.

    Parameters

    deltaTime

    number

    Returns

    boolean

    Sets the priority of the tween.

    Parameters

    priority

    number

    Returns

    Delays the start of the tween animation.

    Parameters

    seconds

    number

    Returns

    Adds additional delay to the tween animation.

    Parameters

    seconds

    number

    Returns

    Sets the duration of the tween animation.

    Parameters

    seconds

    number

    Returns

    Sets the ID of the tween.

    Parameters

    id

    number

    Returns

    Sets whether the tween should be destroyed when stopped.

    Parameters

    value

    boolean

    Returns

    Sets whether the tween should be deactivated when stopped.

    Parameters

    value

    boolean

    Returns

    Sets whether the tween should be disabled when stopped.

    Parameters

    value

    boolean

    Returns

    Sets whether the tween should automatically stop when finished.

    Parameters

    value

    boolean

    Returns

    Creates a ping-pong effect for the tween animation.

    Returns

    Starts the tween animation from a specified point.

    Returns

    Loops the tween animation a specified number of times.

    Parameters

    count

    number

    Returns

    Sets whether the tween should use unscaled time for its animation.

    Parameters

    unscaled

    boolean

    Returns

    Sets the element associated with the tween animation.

    Parameters

    element
    Tween

    Returns

    Applies an ease-in quadratic easing function to the tween.

    Returns

    Applies an ease-out quadratic easing function to the tween.

    Returns

    Applies an ease-in-out quadratic easing function to the tween.

    Returns

    Applies an ease-in cubic easing function to the tween.

    Returns

    Applies an ease-out cubic easing function to the tween.

    Returns

    Applies an ease-in-out cubic easing function to the tween.

    Returns

    Applies an ease-in back easing function to the tween.

    Parameters

    amplitude

    number

    Returns

    Applies an ease-out back easing function to the tween.

    Parameters

    amplitude

    number

    Returns

    Applies an ease-in-out back easing function to the tween.

    Parameters

    amplitude

    number

    Returns

    Applies an ease-in elastic easing function to the tween.

    Parameters

    oscillations

    number

    springiness

    number

    Returns

    Applies an ease-out elastic easing function to the tween.

    Parameters

    oscillations

    number

    springiness

    number

    Returns

    Applies an ease-in-out elastic easing function to the tween.

    Parameters

    oscillations

    number

    springiness

    number

    Returns

    Applies an ease-in bounce easing function to the tween.

    Parameters

    oscillations

    number

    springiness

    number

    Returns

    Applies an ease-out bounce easing function to the tween.

    Parameters

    oscillations

    number

    springiness

    number

    Returns

    Applies an ease-in-out bounce easing function to the tween.

    Parameters

    oscillations

    number

    springiness

    number

    Returns

    Applies an ease-in sine easing function to the tween.

    Returns

    Applies an ease-out sine easing function to the tween.

    Returns

    Applies an ease-in-out sine easing function to the tween.

    Returns

    Applies an ease-in circular easing function to the tween.

    Returns

    Applies an ease-out circular easing function to the tween.

    Returns

    Applies an ease-in-out circular easing function to the tween.

    Returns

    Applies an ease-in exponential easing function to the tween.

    Parameters

    exponent

    number

    Returns

    Applies an ease-out exponential easing function to the tween.

    Parameters

    exponent

    number

    Returns

    Applies an ease-in-out exponential easing function to the tween.

    Parameters

    exponent

    number

    Returns

    Applies an ease-in cubic Bezier easing function to the tween.

    Parameters

    p0

    number

    p1

    number

    p2

    number

    p3

    number

    Returns

    Applies an ease-out cubic Bezier easing function to the tween.

    Parameters

    p0

    number

    p1

    number

    p2

    number

    p3

    number

    Returns

    Applies an ease-in-out cubic Bezier easing function to the tween.

    Parameters

    p0

    number

    p1

    number

    p2

    number

    p3

    number

    Returns

    Resets all tweens.

    Returns

    void

    Stops all tweens.

    Parameters

    executeCallbacks

    boolean

    Returns

    void

    PocketWorlds Icon

    © 2024 Pocket Worlds. All rights reserved.