diff options
author | Tor Andersson <tor@ccxvii.net> | 2022-05-28 12:45:14 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-02-18 12:31:29 +0100 |
commit | 1d68089d06393f6edfa776261b43b3dcc46d95eb (patch) | |
tree | 41e5a1966cfcf04196128fdaef02824e9c4e76f5 | |
parent | 121366f15f7cd4e9bb7c64b668742c9b556dd772 (diff) | |
download | pax-pamir-1d68089d06393f6edfa776261b43b3dcc46d95eb.tar.gz |
Set active player to "None" when game is over.
-rw-r--r-- | play.html | 2 | ||||
-rw-r--r-- | play.js | 2 | ||||
-rw-r--r-- | rules.js | 3 |
3 files changed, 5 insertions, 2 deletions
@@ -53,7 +53,7 @@ </div> <div class="role hide" onclick="scroll_to_player(0)" id="role_Gray"> - <div class="role_name">Gray + <div class="role_name"><span>Gray</span> <div class="role_rupees_icon" id="rupees_0_icon"></div> <div class="role_rupees_text" id="rupees_0_text">15</div> <div class="role_cylinders_icon" id="cylinders_0_icon"></div> @@ -2,7 +2,7 @@ // CONSTANTS -const player_names = [ "Gray", "Blue", "Tan", "Red", "Black" ]; +const player_names = [ "Gray", "Blue", "Tan", "Red", "Black", "None" ]; const player_index = Object.fromEntries(Object.entries(player_names).map(([k,v])=>[v,k|0])); const Persia = 201; @@ -46,6 +46,7 @@ const player_names = [ "Tan", "Red", "Black", + "None" ]; const player_index = Object.fromEntries(Object.entries(player_names).map(([k,v])=>[v,k|0])); @@ -2978,6 +2979,7 @@ function goto_pause_game_over() { function goto_game_over() { compute_victory(); game.state = 'game_over'; + game.active = 5; } states.pause_game_over = { @@ -2988,6 +2990,7 @@ states.pause_game_over = { }, end_game() { game.state = 'game_over'; + game.active = 5; } } |