From d210abfa0f3656f85546ac9c6ed89d3cd0e26b7c Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Fri, 25 Jun 2021 17:41:05 +0200 Subject: New and improved join page with server sent events. --- rules.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/rules.js b/rules.js index e3d01bf..e7f4fc1 100644 --- a/rules.js +++ b/rules.js @@ -2271,9 +2271,11 @@ states.game_over = { }, } +exports.ready = function (scenario, players) { + return players.length === 2; +} + exports.setup = function (scenario, players) { - if (players.length != 2) - throw new Error("Invalid player count: " + players.length); game = { tournament: (scenario == "Tournament"), state: null, -- cgit v1.2.3