From 6c0907a825865956a169d7523b19121ea0e2e700 Mon Sep 17 00:00:00 2001 From: stale Date: Tue, 31 May 2022 18:06:52 -0300 Subject: added config file, room system finished --- assets/index.html | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'assets/index.html') diff --git a/assets/index.html b/assets/index.html index 69f1958..9282726 100644 --- a/assets/index.html +++ b/assets/index.html @@ -38,9 +38,12 @@ fetch("rspace").then(resp => resp.text()).then(roomspace => { let roomspacenum = Number(roomspace); let e = document.getElementById('rspace'); - let t = document.createTextNode("room slots filled, if a room empties of active players it can be replaced by a new one"); + if (roomspacenum == 0) { + e.appendChild(document.createTextNode("all room slots filled, when a room empties it can be replaced by a new one")); + document.getElementById("createbtn").disabled = "disabled"; + } if (roomspacenum == 1) { - e.appendChild(document.createTextNode(`there is one available room slot`)); + e.appendChild(document.createTextNode(`there is 1 available room slot`)); } else if (roomspacenum > 1) { e.appendChild(document.createTextNode(`there are ${roomspacenum} available room slots`)); } @@ -61,7 +64,7 @@


- +
-- cgit v1.2.3