Skip to content

Commit 6735c8e

Browse files
committed
Feature/Fix for issue phaserjs#4510
- Passes through data parameter to Stop()
1 parent 800381b commit 6735c8e

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

src/scene/SceneManager.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1208,16 +1208,17 @@ var SceneManager = new Class({
12081208
* @since 3.0.0
12091209
*
12101210
* @param {string} key - The Scene to stop.
1211+
* @param {object} [data] - Optional data object to pass to Scene.shutdown.
12111212
*
12121213
* @return {Phaser.Scenes.SceneManager} This SceneManager.
12131214
*/
1214-
stop: function (key)
1215+
stop: function (key, data)
12151216
{
12161217
var scene = this.getScene(key);
12171218

12181219
if (scene && !scene.sys.isTransitioning())
12191220
{
1220-
scene.sys.shutdown();
1221+
scene.sys.shutdown(data);
12211222
}
12221223

12231224
return this;

0 commit comments

Comments
 (0)