summaryrefslogtreecommitdiff
path: root/game.js
diff options
context:
space:
mode:
Diffstat (limited to 'game.js')
-rw-r--r--game.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/game.js b/game.js
index 42ca008..dc7a418 100644
--- a/game.js
+++ b/game.js
@@ -530,6 +530,9 @@ window.addEventListener('load', function () {
waitingForServerToGiveUsImageUrl = false;
imageUrl = e.data.substring('useImage '.length);
hostPuzzle();
+ } else if (e.data.startsWith('error ')) {
+ const error = e.data.substring('error '.length);
+ console.error(error); // TODO : better error handling
}
} else {
const opcode = new Uint8Array(e.data, 0, 1)[0];