diff --git a/src/scene/CreditScene.ts b/src/scene/CreditScene.ts index 5c66b48..552a78c 100644 --- a/src/scene/CreditScene.ts +++ b/src/scene/CreditScene.ts @@ -1,3 +1,5 @@ +import { isExhibitionMode } from "../lib/exhibitionMode" + export class CreditScene extends Phaser.Scene { constructor() { super("credit") @@ -113,14 +115,18 @@ export class CreditScene extends Phaser.Scene { .setScale(0.5) .setDepth(1) .setAlpha(0) - .setInteractive({ - useHandCursor: true, - }) - .on("pointerdown", () => { - if (window.open("https://tus-ricora.com/", "_blank") == null) { - location.href = "https://tus-ricora.com/" - } - }) + + if (!isExhibitionMode()) { + link1 + .setInteractive({ + useHandCursor: true, + }) + .on("pointerdown", () => { + if (window.open("https://tus-ricora.com/", "_blank") == null) { + location.href = "https://tus-ricora.com/" + } + }) + } const linkLabel2 = this.add .text(width / 2 - 260, height / 2 - 180 + 330, "View on GitHub", { @@ -142,14 +148,18 @@ export class CreditScene extends Phaser.Scene { .setScale(0.5) .setDepth(1) .setAlpha(0) - .setInteractive({ - useHandCursor: true, - }) - .on("pointerdown", () => { - if (window.open("https://github.com/RICORA/ricora-beats/", "_blank") == null) { - location.href = "https://github.com/RICORA/ricora-beats/" - } - }) + + if (!isExhibitionMode()) { + link2 + .setInteractive({ + useHandCursor: true, + }) + .on("pointerdown", () => { + if (window.open("https://github.com/RICORA/ricora-beats/", "_blank") == null) { + location.href = "https://github.com/RICORA/ricora-beats/" + } + }) + } const closeLabel = this.add .text(width / 2, height / 2 - 180 + 360 * 1.15, "閉じる", { diff --git a/src/scene/ResultScene.ts b/src/scene/ResultScene.ts index 6af136c..3e82b05 100644 --- a/src/scene/ResultScene.ts +++ b/src/scene/ResultScene.ts @@ -1,6 +1,7 @@ import { DebugGUI } from "../class/DebugGUI" import { PlayResult } from "../class/PlayResult" +import { isExhibitionMode } from "../lib/exhibitionMode" import { retryFetch } from "../lib/retryFetch" export class ResultScene extends Phaser.Scene { @@ -639,6 +640,7 @@ export class ResultScene extends Phaser.Scene { .setDepth(10) .setScale(0.8) .setAlpha(0.5) + .setVisible(!isExhibitionMode()) .setInteractive({ useHandCursor: true, }) @@ -681,6 +683,7 @@ export class ResultScene extends Phaser.Scene { .setDepth(10) .setScale(0.8) .setAlpha(0.5) + .setVisible(!isExhibitionMode()) .setInteractive({ useHandCursor: true, }) diff --git a/src/scene/SelectScene.ts b/src/scene/SelectScene.ts index adcf6b6..a0a01b3 100644 --- a/src/scene/SelectScene.ts +++ b/src/scene/SelectScene.ts @@ -8,6 +8,8 @@ import { User } from "../class/User" import { retryFetch } from "../lib/retryFetch" +import { isExhibitionMode } from "../lib/exhibitionMode" + type DIFFICULTY = 1 | 2 | 3 | 4 type KEY = 4 | 5 | 6 | 7 @@ -431,13 +433,21 @@ export class SelectScene extends Phaser.Scene { .image(830 + 400 * 0.5, 640, "icon-ir") .setOrigin(0.5, 0.5) .setDepth(1) - .setInteractive({ - useHandCursor: true, - }) - .on("pointerdown", () => { - this.sound.play("select") - this.scene.run("login") - }) + + if (isExhibitionMode()) { + this.loginIcon.setAlpha(0.5) + this.loginLabel.setAlpha(0.5) + } else { + this.loginIcon + .setInteractive({ + useHandCursor: true, + }) + .on("pointerdown", () => { + this.sound.play("select") + this.scene.run("login") + }) + } + this.add .text(830 + 400 * 0.8, 680, "クレジット", { fontFamily: "Noto Sans JP", @@ -463,6 +473,7 @@ export class SelectScene extends Phaser.Scene { .setOrigin(0, 0) .setAlpha(0.5) .setDepth(1) + .setVisible(!isExhibitionMode()) .setInteractive({ useHandCursor: true, }) @@ -483,6 +494,7 @@ export class SelectScene extends Phaser.Scene { .setOrigin(1, 0) .setAlpha(0.5) .setDepth(1) + .setVisible(!isExhibitionMode()) .setInteractive({ useHandCursor: true, })