Options
All
  • Public
  • Public/Protected
  • All
Menu

Class TweenSleep

Tween that does nothing for specific duration and optionally calls a finished callback at the end,

Hierarchy

  • TweenSleep

Implements

Index

Constructors

constructor

  • Parameters

    • duration: number

      Must be

    • Default value finishedCallback: VoidCallback | undefined = undefined

      A function to call once the tween finishes. Please be mindful of proper this binding when passing methods of a class.

    Returns TweenSleep

Accessors

duration

  • get duration(): number
  • Returns number

isFinished

  • get isFinished(): boolean
  • Returns boolean

remainingDuration

  • get remainingDuration(): number
  • Duration remaining for this tween to run

    Returns number

Methods

advance

  • advance(durationToAdvance: number): number
  • Spends the given duration on this tween.

    Parameters

    • durationToAdvance: number

      Duration to spend on this tween.

    Returns number

    Returns the duration consumed by this tween.

finish

  • finish(): void
  • Instantly finishes the tween, calling the finished callback if it was provided.

    Returns void

skip

  • skip(): void
  • Instantly finishes the tween and does not call the finished callback.

    Returns void

Generated using TypeDoc