summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2022-05-28 12:45:14 +0200
committerTor Andersson <tor@ccxvii.net>2023-02-18 12:31:29 +0100
commit1d68089d06393f6edfa776261b43b3dcc46d95eb (patch)
tree41e5a1966cfcf04196128fdaef02824e9c4e76f5
parent121366f15f7cd4e9bb7c64b668742c9b556dd772 (diff)
downloadpax-pamir-1d68089d06393f6edfa776261b43b3dcc46d95eb.tar.gz
Set active player to "None" when game is over.
-rw-r--r--play.html2
-rw-r--r--play.js2
-rw-r--r--rules.js3
3 files changed, 5 insertions, 2 deletions
diff --git a/play.html b/play.html
index b3cfddd..11613a8 100644
--- a/play.html
+++ b/play.html
@@ -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>
diff --git a/play.js b/play.js
index 7d6a391..485d318 100644
--- a/play.js
+++ b/play.js
@@ -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;
diff --git a/rules.js b/rules.js
index 64e035e..71f2b8f 100644
--- a/rules.js
+++ b/rules.js
@@ -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;
}
}