Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace keydown_SPACE with keydown-SPACE. #382

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions public/src/input/keyboard/cross scene keys.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class SceneA extends Phaser.Scene {
{
let jelly = this.add.image(150, 500, 'jellies', 'WithShadow/Jelly1').setScale(0.5);
let bubble1 = createSpeechBubble(this, 20, 30, 220, 80, "Scene A\nKey.on").setVisible(false);
let bubble2 = createSpeechBubble(this, 20, 160, 220, 80, "Scene A\nkeydown_SPACE").setVisible(false);
let bubble2 = createSpeechBubble(this, 20, 160, 220, 80, "Scene A\nkeydown-SPACE").setVisible(false);
let bubble3 = createSpeechBubble(this, 20, 290, 220, 80, "Scene A\nkeydown").setVisible(false);

let spaceKey = this.input.keyboard.addKey(Phaser.Input.Keyboard.KeyCodes.SPACE);
Expand All @@ -92,7 +92,7 @@ class SceneA extends Phaser.Scene {
// Call stopImmediatePropagation to stop it reaching the global handler in this Scene.
// Call stopPropagation to stop it reaching any other Scene.

this.input.keyboard.on('keydown_SPACE', function (event) {
this.input.keyboard.on('keydown-SPACE', function (event) {

// event.stopPropagation();
// event.stopImmediatePropagation();
Expand Down Expand Up @@ -135,7 +135,7 @@ class SceneB extends Phaser.Scene {
{
let jelly = this.add.image(400, 500, 'jellies', 'WithShadow/Jelly2').setScale(0.5);
let bubble1 = createSpeechBubble(this, 290, 30, 220, 80, "Scene B\nKey.on").setVisible(false);
let bubble2 = createSpeechBubble(this, 290, 160, 220, 80, "Scene B\nkeydown_SPACE").setVisible(false);
let bubble2 = createSpeechBubble(this, 290, 160, 220, 80, "Scene B\nkeydown-SPACE").setVisible(false);
let bubble3 = createSpeechBubble(this, 290, 290, 220, 80, "Scene B\nkeydown").setVisible(false);

let spaceKey = this.input.keyboard.addKey(Phaser.Input.Keyboard.KeyCodes.SPACE);
Expand All @@ -159,7 +159,7 @@ class SceneB extends Phaser.Scene {
// Call stopImmediatePropagation to stop it reaching the global handler in this Scene.
// Call stopPropagation to stop it reaching any other Scene.

this.input.keyboard.on('keydown_SPACE', function (event) {
this.input.keyboard.on('keydown-SPACE', function (event) {

// event.stopPropagation();
// event.stopImmediatePropagation();
Expand Down Expand Up @@ -198,7 +198,7 @@ class SceneC extends Phaser.Scene {
{
let jelly = this.add.image(650, 500, 'jellies', 'WithShadow/Jelly3').setScale(0.5);
let bubble1 = createSpeechBubble(this, 560, 30, 220, 80, "Scene C\nKey.on").setVisible(false);
let bubble2 = createSpeechBubble(this, 560, 160, 220, 80, "Scene C\nkeydown_SPACE").setVisible(false);
let bubble2 = createSpeechBubble(this, 560, 160, 220, 80, "Scene C\nkeydown-SPACE").setVisible(false);
let bubble3 = createSpeechBubble(this, 560, 290, 220, 80, "Scene C\nkeydown").setVisible(false);

let spaceKey = this.input.keyboard.addKey(Phaser.Input.Keyboard.KeyCodes.SPACE);
Expand All @@ -222,7 +222,7 @@ class SceneC extends Phaser.Scene {
// Call stopImmediatePropagation to stop it reaching the global handler in this Scene.
// Call stopPropagation to stop it reaching any other Scene.

this.input.keyboard.on('keydown_SPACE', function (event) {
this.input.keyboard.on('keydown-SPACE', function (event) {

// event.stopPropagation();
// event.stopImmediatePropagation();
Expand Down