From 4ebde57849b41524721377b7e24078d448ad3736 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Thu, 9 Mar 2023 20:27:00 +0100 Subject: Zap unused foreign countries. Darien & Sucumbios reminder tokens. --- play.js | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'play.js') diff --git a/play.js b/play.js index 00ac551..99cc0ef 100644 --- a/play.js +++ b/play.js @@ -63,6 +63,9 @@ const MOM_MISIL_ANTIAEREO = 27 const MOM_SENADO_CAMARA = 42 const MOM_MEXICAN_TRAFFICKERS = 67 +const EVT_SUCUMBIOS = 33 +const EVT_DARIEN = 71 + const senado_class_list = [ "token reminder hide", "token reminder senado_farc", @@ -125,6 +128,8 @@ let ui = { president: document.getElementById("token_el_presidente"), propaganda: document.getElementById("token_prop_card"), senado: document.getElementById("rem_senado"), + darien: document.getElementById("rem_darien"), + sucumbios: document.getElementById("rem_sucumbios"), }, pieces: [], resources: [ @@ -284,6 +289,9 @@ function init_ui() { register_card_tip(ui.momentum[c], c) for (let c of capability_events) register_card_tip(ui.capabilities[c], c) + register_card_tip(ui.tokens.senado, MOM_SENADO_CAMARA) + register_card_tip(ui.tokens.darien, EVT_DARIEN) + register_card_tip(ui.tokens.sucumbios, EVT_SUCUMBIOS) for (let i = 0; i < data.spaces.length; ++i) { let id = data.spaces[i].id @@ -727,6 +735,9 @@ function on_update() { ui.tokens.president.style.left = [ 0, "254px", "337px", "420px" ][view.president] ui.tokens.senado.classList = senado_class_list[view.senado] + ui.tokens.darien.classList.toggle("hide", !set_has(view.capabilities, EVT_DARIEN)) + ui.tokens.sucumbios.classList.toggle("hide", !set_has(view.capabilities, EVT_SUCUMBIOS)) + for (let cap of capability_events) { let shaded = set_has(view.capabilities, -cap) let unshaded = set_has(view.capabilities, cap) -- cgit v1.2.3