DOTS Geometry
 
Loading...
Searching...
No Matches
RandomUtil Class Reference

Static Public Member Functions

static Vector2 OnUnitCircle ()
 Returns a random vector on the unit cirlce.
 
static Vector2 Range (Vector2 min, Vector2 max)
 Returns a random point where each axis is between a minimum and a maximum.
 
static Vector3 Range (Vector3 min, Vector3 max)
 Returns a random point where each axis is between a minimum and a maximum.
 
static Vector3 WithinBounds (Bounds bounds)
 Returns a random point within the given bounds.
 
static Vector2 WithinRectangle (Rect rect)
 Returns a random point within a rectangle.
 

Member Function Documentation

◆ OnUnitCircle()

static Vector2 OnUnitCircle ( )
static

Returns a random vector on the unit cirlce.

Returns

◆ Range() [1/2]

static Vector2 Range ( Vector2 min,
Vector2 max )
static

Returns a random point where each axis is between a minimum and a maximum.

Parameters
min
max
Returns

◆ Range() [2/2]

static Vector3 Range ( Vector3 min,
Vector3 max )
static

Returns a random point where each axis is between a minimum and a maximum.

Parameters
min
max
Returns

◆ WithinBounds()

static Vector3 WithinBounds ( Bounds bounds)
static

Returns a random point within the given bounds.

Parameters
bounds
Returns

◆ WithinRectangle()

static Vector2 WithinRectangle ( Rect rect)
static

Returns a random point within a rectangle.

Parameters
rect
Returns