fix game menu button binds
This commit is contained in:
@@ -5,8 +5,11 @@ AFRAME.registerComponent('debug-state', {
|
||||
play: function () {
|
||||
const flags = AFRAME.utils.getUrlParameter('debugstate').trim();
|
||||
if (!flags) { return; }
|
||||
flags.split(',').forEach(flag => {
|
||||
this.el.sceneEl.emit(`debug${flag.trim()}`, null, false);
|
||||
});
|
||||
|
||||
setTimeout(() => {
|
||||
flags.split(',').forEach(flag => {
|
||||
this.el.sceneEl.emit(`debug${flag.trim()}`, null, false);
|
||||
});
|
||||
}, 500);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
<a-entity
|
||||
id="restartButton"
|
||||
bind-toggle__raycastable="isPaused || isGameOver"
|
||||
bind-visible="isPaused || isGameOver"
|
||||
bind__visible="isPaused || isGameOver"
|
||||
mixin="gameMenuButton"
|
||||
proxy-event="event: click; to: a-scene; as: gamemenurestart">
|
||||
<a-entity mixin="gameMenuButtonText" text="value: RESTART SONG"></a-entity>
|
||||
@@ -48,7 +48,7 @@
|
||||
id="exitButton"
|
||||
mixin="gameMenuButton"
|
||||
bind-toggle__raycastable="isPaused || isGameOver || isVictory"
|
||||
bind-visible="isPaused || isGameOver || isVictory"
|
||||
bind__visible="isPaused || isGameOver || isVictory"
|
||||
position="0 -0.35 0"
|
||||
proxy-event="event: click; to: a-scene; as: gamemenuexit">
|
||||
<a-entity mixin="gameMenuButtonText" text="value: EXIT TO MENU"></a-entity>
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
<a-entity
|
||||
id="multiplier"
|
||||
mixin="scoreText"
|
||||
bind__text="value: multiplierText + 'x'"
|
||||
bind__text="value: score.multiplier + 'x'"
|
||||
text="width: 1"
|
||||
position="1.8 1.2 -4"
|
||||
scale="5 5 5">
|
||||
|
||||
Reference in New Issue
Block a user