From 3efc816a5b086387ae0add23db50ccfe6fa0d8ca Mon Sep 17 00:00:00 2001 From: "Diego F. Goberna" Date: Wed, 10 Oct 2018 02:01:02 +0200 Subject: [PATCH] cleanup --- src/components/debug-states.js | 13 ------------- src/components/pauser.js | 1 - src/templates/debugStates.html | 26 -------------------------- test.html | 33 --------------------------------- 4 files changed, 73 deletions(-) delete mode 100644 src/components/debug-states.js delete mode 100644 src/templates/debugStates.html delete mode 100644 test.html diff --git a/src/components/debug-states.js b/src/components/debug-states.js deleted file mode 100644 index 89aeba1..0000000 --- a/src/components/debug-states.js +++ /dev/null @@ -1,13 +0,0 @@ -AFRAME.registerComponent('debug-states', { - schema: { - isPlaying: {default: false}, - isPaused: {default: false}, - isGameOver: {default: false} - }, - update: function(){ - document.getElementById('debugIsGameOver').className = this.data.isGameOver ? 'active': ''; - document.getElementById('debugIsPaused').className = this.data.isPaused ? 'active': ''; - document.getElementById('debugIsPlaying').className = this.data.isPlaying ? 'active': ''; - console.log(`%c gameover: ${this.data.isGameOver}, paused: ${this.data.isPaused}, playing: ${this.data.isPlaying}`, 'background: #222; color: #bada55'); - } -}); \ No newline at end of file diff --git a/src/components/pauser.js b/src/components/pauser.js index 001a76a..c98275c 100644 --- a/src/components/pauser.js +++ b/src/components/pauser.js @@ -20,7 +20,6 @@ AFRAME.registerComponent('pauser', { events.forEach(event => { this.el.addEventListener(event, this.pauseGame); }); - document.addEventListener('keydown', this.pauseGame); }, pauseGame: function () { diff --git a/src/templates/debugStates.html b/src/templates/debugStates.html deleted file mode 100644 index 96cc58a..0000000 --- a/src/templates/debugStates.html +++ /dev/null @@ -1,26 +0,0 @@ - -
- isGameOver - isPaused - isPlaying -
\ No newline at end of file diff --git a/test.html b/test.html deleted file mode 100644 index 0d3f9fc..0000000 --- a/test.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - - - \ No newline at end of file