From bfd22ff63ef0ffb6771b975e8a389c24eab16567 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Sun, 24 Dec 2023 00:39:32 +0100 Subject: Automatic resign menu. --- play.html | 2 -- rules.js | 20 -------------------- 2 files changed, 22 deletions(-) diff --git a/play.html b/play.html index 4926bca..2d3d96b 100644 --- a/play.html +++ b/play.html @@ -31,8 +31,6 @@
  • Rules
  • Player Aid
  • Cards -
  • -
  • Resign diff --git a/rules.js b/rules.js index f51bbb2..69025e2 100644 --- a/rules.js +++ b/rules.js @@ -3224,26 +3224,6 @@ exports.action = function (state, current, action, arg) { return save_game() } -exports.resign = function (state, current) { - load_game(state) - logbr() - log(`${current} resigned.`) - game.state = 'game_over' - game.active = 5 - game.victory = `${current} resigned.` - - if (game.players.length === 2) { - if (current === player_names[0]) - game.result = player_names[1] - else - game.result = player_names[0] - } else { - game.result = "None" - } - - return save_game() -} - exports.view = function (state, current) { current = player_index[current] load_game(state) -- cgit v1.2.3