Skip to content

Commit 636c5ff

Browse files
committed
Build Phaser CE v2.18.0
1 parent fa9a359 commit 636c5ff

217 files changed

Lines changed: 7810 additions & 7750 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

build/custom/creature.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/custom/p2.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/custom/phaser-arcade-physics.js

Lines changed: 37 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
* Phaser CE - https://github.com/photonstorm/phaser-ce
99
*
10-
* v2.17.0 "2021-03-16" - Built: Tue Mar 16 2021 11:18:44
10+
* v2.18.0 "2021-05-07" - Built: Thu May 06 2021 19:53:35
1111
*
1212
* By Richard Davey http://www.photonstorm.com @photonstorm and Phaser CE contributors
1313
*
@@ -4930,14 +4930,18 @@ PIXI.WebGLSpriteBatch.prototype.end = function ()
49304930
PIXI.WebGLSpriteBatch.prototype.render = function (sprite, matrix)
49314931
{
49324932
var texture = sprite.texture;
4933-
var baseTexture = texture.baseTexture;
4934-
var gl = this.gl;
4935-
if (PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] != baseTexture) // eslint-disable-line eqeqeq
4933+
4934+
if (PIXI._enableMultiTextureToggle)
49364935
{
4937-
this.flush();
4938-
gl.activeTexture(gl.TEXTURE0 + baseTexture.textureIndex);
4939-
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
4940-
PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] = baseTexture;
4936+
var baseTexture = texture.baseTexture;
4937+
var gl = this.gl;
4938+
if (PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] != baseTexture) // eslint-disable-line eqeqeq
4939+
{
4940+
this.flush();
4941+
gl.activeTexture(gl.TEXTURE0 + baseTexture.textureIndex);
4942+
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
4943+
PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] = baseTexture;
4944+
}
49414945
}
49424946

49434947
// They provided an alternative rendering matrix, so use it
@@ -5113,15 +5117,19 @@ PIXI.WebGLSpriteBatch.prototype.render = function (sprite, matrix)
51135117
PIXI.WebGLSpriteBatch.prototype.renderTilingSprite = function (sprite)
51145118
{
51155119
var texture = sprite.tilingTexture;
5116-
var baseTexture = texture.baseTexture;
5117-
var gl = this.gl;
51185120
var textureIndex = sprite.texture.baseTexture.textureIndex;
5119-
if (PIXI.WebGLRenderer.textureArray[textureIndex] != baseTexture) // eslint-disable-line eqeqeq
5121+
5122+
if (PIXI._enableMultiTextureToggle)
51205123
{
5121-
this.flush();
5122-
gl.activeTexture(gl.TEXTURE0 + textureIndex);
5123-
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
5124-
PIXI.WebGLRenderer.textureArray[textureIndex] = baseTexture;
5124+
var baseTexture = texture.baseTexture;
5125+
var gl = this.gl;
5126+
if (PIXI.WebGLRenderer.textureArray[textureIndex] != baseTexture) // eslint-disable-line eqeqeq
5127+
{
5128+
this.flush();
5129+
gl.activeTexture(gl.TEXTURE0 + textureIndex);
5130+
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
5131+
PIXI.WebGLRenderer.textureArray[textureIndex] = baseTexture;
5132+
}
51255133
}
51265134

51275135
// check texture..
@@ -5356,8 +5364,10 @@ PIXI.WebGLSpriteBatch.prototype.flush = function ()
53565364
skip = false;
53575365
}
53585366

5359-
//
5360-
if (/* (currentBaseTexture !== nextTexture && !skip) || */
5367+
// if multi-texture batching disabled we always render the batch upon switching textures
5368+
var multiTextureBatchingEnabled = PIXI._enableMultiTextureToggle;
5369+
var baseTextureChanged = currentBaseTexture !== nextTexture;
5370+
if ((!multiTextureBatchingEnabled && baseTextureChanged && !skip) ||
53615371
blendSwap ||
53625372
shaderSwap)
53635373
{
@@ -7774,7 +7784,7 @@ var Phaser = Phaser || { // jshint ignore:line
77747784
* @constant Phaser.VERSION
77757785
* @type {string}
77767786
*/
7777-
VERSION: '2.17.0',
7787+
VERSION: '2.18.0',
77787788

77797789
/**
77807790
* An array of Phaser game instances.
@@ -59377,14 +59387,14 @@ Phaser.Cache.prototype = {
5937759387
*/
5937859388

5937959389
/**
59380-
* Add a new canvas object in to the cache.
59390+
* Add a new compressed texture in to the cache.
5938159391
*
5938259392
* @method Phaser.Cache#addCompressedTextureMetaData
5938359393
* @private
5938459394
* @param {string} key - The key that this asset will be stored in the cache under. This should be unique within this cache.
59385-
* @param {string} url
59386-
* @param {string} extension
59387-
* @param {array} arrayBuffer
59395+
* @param {string} url - The URL the asset was loaded from. If the asset was not loaded externally set to `null`.
59396+
* @param {string} extension - The extension of the compressed texture.
59397+
* @param {ArrayBuffer} arrayBuffer - The compressed texture data.
5938859398
* @return {object} The compressed texture entry.
5938959399
*/
5939059400
addCompressedTextureMetaData: function (key, url, extension, arrayBuffer)
@@ -63961,6 +63971,7 @@ Phaser.Loader.prototype = {
6396163971

6396263972
file.data = document.createElement('video');
6396363973
file.data.name = file.key;
63974+
file.data.crossOrigin = this.crossOrigin;
6396463975
file.data.controls = false;
6396563976
file.data.autoplay = false;
6396663977
file.data.playsInline = true;
@@ -88440,11 +88451,11 @@ Phaser.Video.prototype = {
8844088451

8844188452
if (loop)
8844288453
{
88443-
this.video.loop = 'loop';
88454+
this.video.loop = true;
8844488455
}
8844588456
else
8844688457
{
88447-
this.video.loop = '';
88458+
this.video.loop = false;
8844888459
}
8844988460

8845088461
this.video.playbackRate = playbackRate;
@@ -89135,11 +89146,11 @@ Object.defineProperty(Phaser.Video.prototype, 'loop', {
8913589146
{
8913689147
if (value && this.video)
8913789148
{
89138-
this.video.loop = 'loop';
89149+
this.video.loop = true;
8913989150
}
8914089151
else if (this.video)
8914189152
{
89142-
this.video.loop = '';
89153+
this.video.loop = false;
8914389154
}
8914489155
}
8914589156

build/custom/phaser-arcade-physics.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/custom/phaser-arcade-physics.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/custom/phaser-creature.js

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
* Phaser CE - https://github.com/photonstorm/phaser-ce
99
*
10-
* v2.17.0 "2021-03-16" - Built: Tue Mar 16 2021 11:19:01
10+
* v2.18.0 "2021-05-07" - Built: Thu May 06 2021 19:53:52
1111
*
1212
* By Richard Davey http://www.photonstorm.com @photonstorm and Phaser CE contributors
1313
*
@@ -40,7 +40,7 @@ var Phaser = Phaser || { // jshint ignore:line
4040
* @constant Phaser.VERSION
4141
* @type {string}
4242
*/
43-
VERSION: '2.17.0',
43+
VERSION: '2.18.0',
4444

4545
/**
4646
* An array of Phaser game instances.
@@ -51643,14 +51643,14 @@ Phaser.Cache.prototype = {
5164351643
*/
5164451644

5164551645
/**
51646-
* Add a new canvas object in to the cache.
51646+
* Add a new compressed texture in to the cache.
5164751647
*
5164851648
* @method Phaser.Cache#addCompressedTextureMetaData
5164951649
* @private
5165051650
* @param {string} key - The key that this asset will be stored in the cache under. This should be unique within this cache.
51651-
* @param {string} url
51652-
* @param {string} extension
51653-
* @param {array} arrayBuffer
51651+
* @param {string} url - The URL the asset was loaded from. If the asset was not loaded externally set to `null`.
51652+
* @param {string} extension - The extension of the compressed texture.
51653+
* @param {ArrayBuffer} arrayBuffer - The compressed texture data.
5165451654
* @return {object} The compressed texture entry.
5165551655
*/
5165651656
addCompressedTextureMetaData: function (key, url, extension, arrayBuffer)
@@ -56227,6 +56227,7 @@ Phaser.Loader.prototype = {
5622756227

5622856228
file.data = document.createElement('video');
5622956229
file.data.name = file.key;
56230+
file.data.crossOrigin = this.crossOrigin;
5623056231
file.data.controls = false;
5623156232
file.data.autoplay = false;
5623256233
file.data.playsInline = true;
@@ -87362,11 +87363,11 @@ Phaser.Video.prototype = {
8736287363

8736387364
if (loop)
8736487365
{
87365-
this.video.loop = 'loop';
87366+
this.video.loop = true;
8736687367
}
8736787368
else
8736887369
{
87369-
this.video.loop = '';
87370+
this.video.loop = false;
8737087371
}
8737187372

8737287373
this.video.playbackRate = playbackRate;
@@ -88057,11 +88058,11 @@ Object.defineProperty(Phaser.Video.prototype, 'loop', {
8805788058
{
8805888059
if (value && this.video)
8805988060
{
88060-
this.video.loop = 'loop';
88061+
this.video.loop = true;
8806188062
}
8806288063
else if (this.video)
8806388064
{
88064-
this.video.loop = '';
88065+
this.video.loop = false;
8806588066
}
8806688067
}
8806788068

build/custom/phaser-creature.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/custom/phaser-creature.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/custom/phaser-minimum.js

Lines changed: 33 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
* Phaser CE - https://github.com/photonstorm/phaser-ce
99
*
10-
* v2.17.0 "2021-03-16" - Built: Tue Mar 16 2021 11:18:52
10+
* v2.18.0 "2021-05-07" - Built: Thu May 06 2021 19:53:43
1111
*
1212
* By Richard Davey http://www.photonstorm.com @photonstorm and Phaser CE contributors
1313
*
@@ -4930,14 +4930,18 @@ PIXI.WebGLSpriteBatch.prototype.end = function ()
49304930
PIXI.WebGLSpriteBatch.prototype.render = function (sprite, matrix)
49314931
{
49324932
var texture = sprite.texture;
4933-
var baseTexture = texture.baseTexture;
4934-
var gl = this.gl;
4935-
if (PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] != baseTexture) // eslint-disable-line eqeqeq
4933+
4934+
if (PIXI._enableMultiTextureToggle)
49364935
{
4937-
this.flush();
4938-
gl.activeTexture(gl.TEXTURE0 + baseTexture.textureIndex);
4939-
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
4940-
PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] = baseTexture;
4936+
var baseTexture = texture.baseTexture;
4937+
var gl = this.gl;
4938+
if (PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] != baseTexture) // eslint-disable-line eqeqeq
4939+
{
4940+
this.flush();
4941+
gl.activeTexture(gl.TEXTURE0 + baseTexture.textureIndex);
4942+
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
4943+
PIXI.WebGLRenderer.textureArray[baseTexture.textureIndex] = baseTexture;
4944+
}
49414945
}
49424946

49434947
// They provided an alternative rendering matrix, so use it
@@ -5113,15 +5117,19 @@ PIXI.WebGLSpriteBatch.prototype.render = function (sprite, matrix)
51135117
PIXI.WebGLSpriteBatch.prototype.renderTilingSprite = function (sprite)
51145118
{
51155119
var texture = sprite.tilingTexture;
5116-
var baseTexture = texture.baseTexture;
5117-
var gl = this.gl;
51185120
var textureIndex = sprite.texture.baseTexture.textureIndex;
5119-
if (PIXI.WebGLRenderer.textureArray[textureIndex] != baseTexture) // eslint-disable-line eqeqeq
5121+
5122+
if (PIXI._enableMultiTextureToggle)
51205123
{
5121-
this.flush();
5122-
gl.activeTexture(gl.TEXTURE0 + textureIndex);
5123-
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
5124-
PIXI.WebGLRenderer.textureArray[textureIndex] = baseTexture;
5124+
var baseTexture = texture.baseTexture;
5125+
var gl = this.gl;
5126+
if (PIXI.WebGLRenderer.textureArray[textureIndex] != baseTexture) // eslint-disable-line eqeqeq
5127+
{
5128+
this.flush();
5129+
gl.activeTexture(gl.TEXTURE0 + textureIndex);
5130+
gl.bindTexture(gl.TEXTURE_2D, baseTexture._glTextures[gl.id]);
5131+
PIXI.WebGLRenderer.textureArray[textureIndex] = baseTexture;
5132+
}
51255133
}
51265134

51275135
// check texture..
@@ -5356,8 +5364,10 @@ PIXI.WebGLSpriteBatch.prototype.flush = function ()
53565364
skip = false;
53575365
}
53585366

5359-
//
5360-
if (/* (currentBaseTexture !== nextTexture && !skip) || */
5367+
// if multi-texture batching disabled we always render the batch upon switching textures
5368+
var multiTextureBatchingEnabled = PIXI._enableMultiTextureToggle;
5369+
var baseTextureChanged = currentBaseTexture !== nextTexture;
5370+
if ((!multiTextureBatchingEnabled && baseTextureChanged && !skip) ||
53615371
blendSwap ||
53625372
shaderSwap)
53635373
{
@@ -7774,7 +7784,7 @@ var Phaser = Phaser || { // jshint ignore:line
77747784
* @constant Phaser.VERSION
77757785
* @type {string}
77767786
*/
7777-
VERSION: '2.17.0',
7787+
VERSION: '2.18.0',
77787788

77797789
/**
77807790
* An array of Phaser game instances.
@@ -42668,14 +42678,14 @@ Phaser.Cache.prototype = {
4266842678
*/
4266942679

4267042680
/**
42671-
* Add a new canvas object in to the cache.
42681+
* Add a new compressed texture in to the cache.
4267242682
*
4267342683
* @method Phaser.Cache#addCompressedTextureMetaData
4267442684
* @private
4267542685
* @param {string} key - The key that this asset will be stored in the cache under. This should be unique within this cache.
42676-
* @param {string} url
42677-
* @param {string} extension
42678-
* @param {array} arrayBuffer
42686+
* @param {string} url - The URL the asset was loaded from. If the asset was not loaded externally set to `null`.
42687+
* @param {string} extension - The extension of the compressed texture.
42688+
* @param {ArrayBuffer} arrayBuffer - The compressed texture data.
4267942689
* @return {object} The compressed texture entry.
4268042690
*/
4268142691
addCompressedTextureMetaData: function (key, url, extension, arrayBuffer)
@@ -47252,6 +47262,7 @@ Phaser.Loader.prototype = {
4725247262

4725347263
file.data = document.createElement('video');
4725447264
file.data.name = file.key;
47265+
file.data.crossOrigin = this.crossOrigin;
4725547266
file.data.controls = false;
4725647267
file.data.autoplay = false;
4725747268
file.data.playsInline = true;

build/custom/phaser-minimum.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)