Skip to content

Range

Namespace: SideXP.Core

public struct Range

Represents a range between a minimum and a maximum.

Constructors

Range(float)

public Range(float max)

Represents a range between 0 and a given maximum.

Range(float, float)

public Range(float min, float max)

Represents a range between a minimum and a maximum.

Parameters

  • min: The minimum value of this range.
  • min: The maximum value of this range.

Range(Range)

public Range(Range other)

Parameters

  • other: The range to copy.

Properties

Min

public float Min

Inherited documentation.

Max

public float Max

Inherited documentation.

Delta

public float Delta

Returns the delta between min and max, basically the result of (max - min).

Random

public float Random

Gets a random value between min and max, both inclusive.