From 3deaf7e3bfe4bbcfb81b90c92587e36f72c03362 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Tue, 21 Feb 2023 11:34:46 +0100 Subject: Darken turns before the start of the scenario too. --- play.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'play.js') diff --git a/play.js b/play.js index d7e851b..f33e023 100644 --- a/play.js +++ b/play.js @@ -1682,10 +1682,12 @@ function on_update() { update_court() + let first_turn = view.scenario >> 5 + let last_turn = view.scenario & 31 for (let i = 0; i <= 17; ++i) { ui.calendar[i].classList.toggle("action", is_action("calendar", i)) if (i >= 1 && i <= 16) - ui.calendar[i].classList.toggle("end", i > view.end) + ui.calendar[i].classList.toggle("end", i < first_turn || i > last_turn) } // Misc -- cgit v1.2.3