From 84c24862cf674616d928798a31fff195f2d52c14 Mon Sep 17 00:00:00 2001 From: Richard Davey Date: Sun, 24 Feb 2019 22:56:29 +0000 Subject: [PATCH] `GetAdvancedValue` now uses the correct Math RND reference, which means anything that used the `randInt` or `randFloat` features of this function, such as creating a Sprite from a Config object, or Bitmap Text sizing, will no longer throw an error about a null object reference. Fix #4369 --- CHANGELOG.md | 1 + src/utils/object/GetAdvancedValue.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8c0cdd882..c279ca887 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ ### Bug Fixes * The parent bounds are reset when exiting fullscreen mode in the Scale Manager. This fixes an issue when leaving fullscreen mode by pressing ESC (instead of programmatically) would leave the canvas in the full screen size. Fix #4357 (thanks @khutchins and @HeyStevenXu) +* `GetAdvancedValue` now uses the correct Math RND reference, which means anything that used the `randInt` or `randFloat` features of this function, such as creating a Sprite from a Config object, or Bitmap Text sizing, will no longer throw an error about a null object reference. Fix #4369 (thanks @sanadov) ### Examples, Documentation and TypeScript diff --git a/src/utils/object/GetAdvancedValue.js b/src/utils/object/GetAdvancedValue.js index aeb4ee050..36f4d40bf 100644 --- a/src/utils/object/GetAdvancedValue.js +++ b/src/utils/object/GetAdvancedValue.js @@ -4,7 +4,7 @@ * @license {@link https://github.com/photonstorm/phaser/blob/master/license.txt|MIT License} */ -var MATH = require('../../math/const'); +var MATH = require('../../math'); var GetValue = require('./GetValue'); /**