Phaser API Documentation

  Version: 

Member of: Phaser.Math

<static> FloatBetween(min, max)

Description:

Generate a random floating point number between the two given bounds, minimum inclusive, maximum exclusive.

Parameters:

name type description
min number

The lower bound for the float, inclusive.

max number

The upper bound for the float exclusive.

Returns:
Description:

A random float within the given range.

Type:
  • number
Examples:
Since: 3.0.0
Source: src/math/FloatBetween.js (Line 7)