Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Methods

  • activate(enable: boolean): void
  • activated(): boolean
  • addColorEffectPropertyTween(effectBehavior: any, identifier: string, toColorStr: string, effectName: string, propertyName: string, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween a color object effect property.

    Parameters

    • effectBehavior: any

      Only used by events can be set to null

    • identifier: string

      Unique id to identify the tween

    • toColorStr: string

      The target RGB color (format "128;200;255" with values between 0 and 255 for red, green and blue)

    • effectName: string

      Effect name

    • propertyName: string

      Property name

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addNumberEffectPropertyTween(effectBehavior: any, identifier: string, toValue: number, effectName: string, propertyName: string, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween a numeric object effect property.

    Parameters

    • effectBehavior: any

      Only used by events can be set to null

    • identifier: string

      Unique id to identify the tween

    • toValue: number

      The targeted value

    • effectName: string

      Effect name

    • propertyName: string

      Property name

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectAngleTween(identifier: string, toAngle: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object angle.

    deprecated

    Use addObjectAngleTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toAngle: number

      The target angle

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectAngleTween2(identifier: string, toAngle: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object angle.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toAngle: number

      The target angle

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectColorHSLTween(identifier: string, toHue: number, animateHue: boolean, toSaturation: number, toLightness: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object HSL color, with the "to" color given using HSL (H: any number, S and L: 0-100).

    deprecated

    Use addObjectColorHSLTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toHue: number

      The target hue, or the same as the from color's hue if blank

    • animateHue: boolean
    • toSaturation: number

      The target saturation, or the same as the from color's saturation if blank

    • toLightness: number

      The target lightness, or the same as the from color's lightness if blank

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectColorHSLTween2(identifier: string, toHue: number, animateHue: boolean, toSaturation: number, toLightness: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object HSL color, with the "to" color given using HSL (H: any number, S and L: 0-100).

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toHue: number

      The target hue, or the same as the from color's hue if blank

    • animateHue: boolean
    • toSaturation: number

      The target saturation, or the same as the from color's saturation if blank

    • toLightness: number

      The target lightness, or the same as the from color's lightness if blank

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectColorTween(identifier: string, toColorStr: string, easing: string, duration: number, destroyObjectWhenFinished: boolean, useHSLColorTransition: boolean): void
  • Tween an object color.

    deprecated

    Use addObjectColorTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toColorStr: string

      The target RGB color (format "128;200;255" with values between 0 and 255 for red, green and blue)

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • useHSLColorTransition: boolean

      Tween using HSL color mappings, rather than direct RGB line

    Returns void

  • addObjectColorTween2(identifier: string, toColorStr: string, easing: string, duration: number, destroyObjectWhenFinished: boolean, useHSLColorTransition?: boolean): void
  • Tween an object color.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toColorStr: string

      The target RGB color (format "128;200;255" with values between 0 and 255 for red, green and blue)

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • useHSLColorTransition: boolean = true

      Tween using HSL color mappings, rather than direct RGB line

    Returns void

  • addObjectDepthTween(identifier: string, toDepth: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object depth.

    deprecated

    Use addObjectDepthTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toDepth: number

      The target depth

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectDepthTween2(object3DBehavior: any, identifier: string, toDepth: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object depth.

    Parameters

    • object3DBehavior: any

      Only used by events can be set to null

    • identifier: string

      Unique id to identify the tween

    • toDepth: number

      The target depth

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectHeightTween(identifier: string, toHeight: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object height.

    deprecated

    Use addObjectHeightTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toHeight: number

      The target height

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectHeightTween2(identifier: string, toHeight: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object height.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toHeight: number

      The target height

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectOpacityTween(identifier: string, toOpacity: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object opacity.

    deprecated

    Use addObjectOpacityTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toOpacity: number

      The target opacity

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectOpacityTween2(identifier: string, toOpacity: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object opacity.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toOpacity: number

      The target opacity

    • easing: string

      Easing function identifier

    • duration: number

      Duration in second

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionTween(identifier: string, toX: number, toY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object position.

    deprecated

    Use addObjectPositionTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toX: number

      The target X position

    • toY: number

      The target Y position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionTween2(identifier: string, toX: number, toY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object position.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toX: number

      The target X position

    • toY: number

      The target Y position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionXTween(identifier: string, toX: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object X position.

    deprecated

    Use addObjectPositionXTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toX: number

      The target X position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionXTween2(identifier: string, toX: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object X position.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toX: number

      The target X position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionYTween(identifier: string, toY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object Y position.

    deprecated

    Use addObjectPositionYTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toY: number

      The target Y position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionYTween2(identifier: string, toY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object Y position.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toY: number

      The target Y position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionZTween(identifier: string, toZ: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object Z position.

    deprecated

    Use addObjectPositionZTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toZ: number

      The target Z position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectPositionZTween2(object3DBehavior: any, identifier: string, toZ: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object Z position.

    Parameters

    • object3DBehavior: any

      Only used by events can be set to null

    • identifier: string

      Unique id to identify the tween

    • toZ: number

      The target Z position

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectRotationXTween(object3DBehavior: any, identifier: string, toAngle: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween a 3D object rotation X.

    Parameters

    • object3DBehavior: any

      Only used by events can be set to null

    • identifier: string

      Unique id to identify the tween

    • toAngle: number

      The target angle

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectRotationYTween(object3DBehavior: any, identifier: string, toAngle: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween a 3D object rotation Y.

    Parameters

    • object3DBehavior: any

      Only used by events can be set to null

    • identifier: string

      Unique id to identify the tween

    • toAngle: number

      The target angle

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectScaleTween(identifier: string, toScaleX: number, toScaleY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean, scaleFromCenterOfObject: boolean): void
  • Tween an object scale.

    deprecated

    Use addObjectScaleTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toScaleX: number

      The target X-scale

    • toScaleY: number

      The target Y-scale

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • scaleFromCenterOfObject: boolean

      Scale the transform from the center of the object (or point that is called center), not the top-left origin

    Returns void

  • addObjectScaleTween2(identifier: string, toScaleX: number, toScaleY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean, scaleFromCenterOfObject: boolean): void
  • Tween an object scale.

    deprecated

    Use addObjectScaleXTween2 and addObjectScaleYTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toScaleX: number

      The target X-scale

    • toScaleY: number

      The target Y-scale

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • scaleFromCenterOfObject: boolean

      Scale the transform from the center of the object (or point that is called center), not the top-left origin

    Returns void

  • addObjectScaleTween3(identifier: string, toScale: number, easing: string, duration: number, destroyObjectWhenFinished: boolean, scaleFromCenterOfObject: boolean): void
  • Tween an object scale.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toScale: number

      The target scale

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • scaleFromCenterOfObject: boolean

      Scale the transform from the center of the object (or point that is called center), not the top-left origin

    Returns void

  • addObjectScaleXTween(identifier: string, toScaleX: number, easing: string, duration: number, destroyObjectWhenFinished: boolean, scaleFromCenterOfObject: boolean): void
  • Tween an object X-scale.

    deprecated

    Use addObjectScaleXTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toScaleX: number

      The target X-scale

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • scaleFromCenterOfObject: boolean

      Scale the transform from the center of the object (or point that is called center), not the top-left origin

    Returns void

  • addObjectScaleXTween2(identifier: string, toScaleX: number, easing: string, duration: number, destroyObjectWhenFinished: boolean, scaleFromCenterOfObject: boolean): void
  • Tween an object X-scale.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toScaleX: number

      The target X-scale

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • scaleFromCenterOfObject: boolean

      Scale the transform from the center of the object (or point that is called center), not the top-left origin

    Returns void

  • addObjectScaleYTween(identifier: string, toScaleY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean, scaleFromCenterOfObject: boolean): void
  • Tween an object Y-scale.

    deprecated

    Use addObjectScaleYTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toScaleY: number

      The target Y-scale

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • scaleFromCenterOfObject: boolean

      Scale the transform from the center of the object (or point that is called center), not the top-left origin

    Returns void

  • addObjectScaleYTween2(identifier: string, toScaleY: number, easing: string, duration: number, destroyObjectWhenFinished: boolean, scaleFromCenterOfObject: boolean): void
  • Tween an object Y-scale.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toScaleY: number

      The target Y-scale

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    • scaleFromCenterOfObject: boolean

      Scale the transform from the center of the object (or point that is called center), not the top-left origin

    Returns void

  • addObjectWidthTween(identifier: string, toWidth: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object width.

    deprecated

    Use addObjectWidthTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toWidth: number

      The target width

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addObjectWidthTween2(identifier: string, toWidth: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object width.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toWidth: number

      The target width

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addTextObjectCharacterSizeTween(identifier: string, toSize: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween a text object character size.

    deprecated

    Use addTextObjectCharacterSizeTween2 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toSize: number

      The target character size

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addTextObjectCharacterSizeTween2(identifier: string, toSize: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween a text object character size.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • toSize: number

      The target character size

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addValueTween(identifier: string, fromValue: number, toValue: number, easing: string, duration: number, useExponentialInterpolation: boolean, destroyObjectWhenFinished: boolean): void
  • Add an object value tween.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • fromValue: number

      Start value

    • toValue: number

      End value

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • useExponentialInterpolation: boolean

      Set it to true to use a exponential It's useful for values that are factors like a scale or a zoom.

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addVariableTween(identifier: string, variable: Variable, fromValue: number, toValue: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Add an object variable tween.

    deprecated

    Use addVariableTween3 instead. This function is misleading since one could think that the tween starts right at the moment this function is called whereas the value of the variable will change at the next frame only. Moreover, the variable will not start from the start value exactly since time will have passed at the moment the next frame is rendered. See https://github.com/4ian/GDevelop/issues/4270

    Parameters

    • identifier: string

      Unique id to identify the tween

    • variable: Variable

      The object variable to store the tweened value

    • fromValue: number

      Start value

    • toValue: number

      End value

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addVariableTween2(identifier: string, variable: Variable, toValue: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object variable.

    deprecated

    Use addVariableTween3 instead.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • variable: Variable

      The object variable to store the tweened value

    • toValue: number

      End value

    • easing: string

      Easing function identifier

    • duration: number

      Duration in milliseconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • addVariableTween3(identifier: string, variable: Variable, toValue: number, easing: string, duration: number, destroyObjectWhenFinished: boolean): void
  • Tween an object variable.

    Parameters

    • identifier: string

      Unique id to identify the tween

    • variable: Variable

      The object variable to store the tweened value

    • toValue: number

      End value

    • easing: string

      Easing function identifier

    • duration: number

      Duration in seconds

    • destroyObjectWhenFinished: boolean

      Destroy this object when the tween ends

    Returns void

  • exists(identifier: string): boolean
  • getName(): string
  • getNameId(): number
  • getProgress(identifier: string): number
  • getValue(identifier: string): number
  • hasFinished(identifier: string): boolean
  • isPlaying(identifier: string): boolean
  • onActivate(): void
  • onCreated(): void
  • onDeActivate(): void
  • onDestroy(): void
  • This method is called when the owner of the behavior is being removed from the scene and is about to be destroyed/reused later or when the behavior is removed from an object (can happen in case of hot-reloading only. Otherwise, behaviors are just de-activated, not removed. See onDeActivate).

    Returns void

  • onObjectHotReloaded(): void
  • pauseTween(identifier: string): void
  • removeTween(identifier: string): void
  • resumeTween(identifier: string): void
  • stopTween(identifier: string, jumpToDest: boolean): void
  • updateFromBehaviorData(oldBehaviorData: BehaviorData, newBehaviorData: BehaviorData): boolean
  • Called when the behavior must be updated using the specified behaviorData. This is the case during hot-reload, and is only called if the behavior was modified.

    Parameters

    • oldBehaviorData: BehaviorData
    • newBehaviorData: BehaviorData

    Returns boolean

    true if the behavior was updated, false if it could not (i.e: hot-reload is not supported).

  • usesLifecycleFunction(): boolean
  • Should return false if the behavior does not need any lifecycle function to be called. Default, hidden, "capability" behaviors set it to false. This avoids useless calls to empty lifecycle functions, which would waste CPU time (and have a sizeable impact for example when lots of static instances are living in the scene).

    Returns boolean

Constructors

Properties

name: string
type: string

Generated using TypeDoc