From b182557d039d125bf94e253370fa320df159cae2 Mon Sep 17 00:00:00 2001 From: Richard Davey Date: Tue, 8 Nov 2022 23:21:25 +0000 Subject: [PATCH] Added canInput method --- src/scene/Systems.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/scene/Systems.js b/src/scene/Systems.js index 9e5c2b980..2c39ab10c 100644 --- a/src/scene/Systems.js +++ b/src/scene/Systems.js @@ -572,6 +572,21 @@ var Systems = new Class({ return this.settings.status; }, + /** + * Can this Scene receive Input events? + * + * @method Phaser.Scenes.Systems#canInput + * @since 3.60.0 + * + * @return {boolean} `true` if this Scene can receive Input events. + */ + canInput: function () + { + var status = this.settings.status; + + return (status > CONST.PENDING && status <= CONST.RUNNING); + }, + /** * Is this Scene sleeping? *