diff --git a/test-wsplay/ws.js b/test-wsplay/ws.js index 4786b42..17c57f3 100644 --- a/test-wsplay/ws.js +++ b/test-wsplay/ws.js @@ -10,7 +10,9 @@ msrc = document.getElementById("msrc"), climax = document.getElementById("climax"); var conn, PORT=8804, server = location.hostname; - server = "wss://www.iekei.org/hayaoshi/" + //server = "wss://www.iekei.org/hayaoshi/" + server = "ws://localhost:8804/" + var pauseTime, musicinfo; function sendmsg(str) { conn.send(JSON.stringify({team: team.value, state: str})); @@ -49,6 +51,7 @@ console.log("data: "+cmd); if (cmd.match(/src=(.*)/)) { musicinfo = JSON.parse(RegExp.$1); + console.log(musicinfo); let url = musicinfo.url; music.setAttribute("src", url); myinfo.textContent = "Loading music..."; @@ -64,7 +67,7 @@ var a=parseInt(RegExp.$1), b=parseInt(RegExp.$2); // alert(a+"..."+b); if (a>=b) { - play.textContent = " PLAYxxx "; + // play.textContent = " PLAYxxx "; info.textContent = music.getAttribute("src"); play.disabled = false; } else {