From da4483419158f76c1a1373e327d9992f8d94f636 Mon Sep 17 00:00:00 2001 From: Marty Killian Date: Wed, 13 Dec 2023 13:58:34 +0100 Subject: [PATCH] phone focus fix --- public_html/js/game.js | 2 +- public_html/js/network.js | 1 + public_html/js/phone.js | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/public_html/js/game.js b/public_html/js/game.js index f3da7e5..3e57bf3 100644 --- a/public_html/js/game.js +++ b/public_html/js/game.js @@ -36,4 +36,4 @@ function game() { net.connect(); //connect to server, create a player, and retrieve all players info -setInterval(game); \ No newline at end of file +setInterval(game, 16); \ No newline at end of file diff --git a/public_html/js/network.js b/public_html/js/network.js index a39689c..b9b943b 100644 --- a/public_html/js/network.js +++ b/public_html/js/network.js @@ -7,6 +7,7 @@ class Network{ message(data){ switch(data.type){ + case 'connect': this.playerId = data.data.playerId; for (let i = 0; i