Class Vector3Distribution

Specifies a value as a distribution, which can include a constant value, random range or a curve.

Hierarchy

  • FrameworkObject
    • Vector3Distribution

Constructors

Accessors

  • get length(): number
  • Returns the length of the distribution curve. This is 0 for PropertyDistributionType::Constant and PropertyDistributionType::RandomRange modes. For PropertyDistributionType::Curve mode, this is the length of the curve, and for PropertyDistributionType::CurveRange it is the length of the minimum or maximum curve, whichever is longer.

    Returns number

Methods

  • Evaluates the value of the distribution.

    Parameters

    • t: number

      Time at which to evaluate the distribution. This is only relevant if the distribution contains curves.

    • factor: number

      Value in range [0, 1] that determines how to interpolate between min/max value, if the distribution represents a range. Value of 0 will return the minimum value, while value of 1 will return the maximum value, and interpolate the values in-between.

    Returns Vector3

    Evaluated value.

  • Evaluates the value of the distribution.

    Parameters

    • t: number

      Time at which to evaluate the distribution. This is only relevant if the distribution contains curves.

    • factorGenerator: Random

      Random number generator that determines the factor. Factor determines how to interpolate between min/max value, if the distribution represents a range.

    Returns Vector3

    Evaluated value.

  • Evaluates the value of the distribution at a normalized time.

    Parameters

    • t: number

      Normalized time at which to evaluate the distribution. This is only relevant if the distribution contains curves. 0 is the start of the curves, 1 is the end of the curves.

    • factor: number

      Value in range [0, 1] that determines how to interpolate between min/max value, if the distribution represents a range. Value of 0 will return the minimum value, while value of 1 will return the maximum value, and interpolate the values in-between.

    Returns Vector3

    Evaluated value.

  • Evaluates the value of the distribution at a normalized time.

    Parameters

    • t: number

      Normalized time at which to evaluate the distribution. This is only relevant if the distribution contains curves. 0 is the start of the curves, 1 is the end of the curves.

    • factorGenerator: Random

      Random number generator that determines the factor. Factor determines how to interpolate between min/max value, if the distribution represents a range.

    Returns Vector3

    Evaluated value.

  • Returns the maximum value of a constant range. Only defined if the distribution represents a non-curve range.

    Returns Vector3

  • Returns the constant value of the distribution, or the minimal value of a constant range. Undefined if the distribution is represented by a curve.

    Returns Vector3

  • Returns the curve representing the distribution, or the first curve representing a curve range. Undefined if the distribution is represented by a constant or a non-curve range.

    Returns CompoundVector3Curve

  • Compares two distributions for equality.

    Parameters

    Returns boolean