Random number

Introduction

Get random value, built-in methods of phaser.

  • Author: Richard Davey

Usage

Get random integer between (min, max)

var value = Phaser.Math.Between(min, max);

Get random vector

var vec = Phaser.Math.RandomXY(vec);    // return vec {x, y}
// var vec = Phaser.Math.RandomXY(vec, scale);