From b6a4fdc6fc83525ceda1451df98baf80ec47d63c Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Sat, 31 Jul 2021 20:11:02 +0200 Subject: 300: Limit transported armies to 3! --- ui.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ui.js') diff --git a/ui.js b/ui.js index 4806eb5..b6a2510 100644 --- a/ui.js +++ b/ui.js @@ -105,7 +105,7 @@ function on_click_army(evt) { if (ui.selected_armies && ui.selected_armies.includes(evt.target)) { remove_from_array(ui.selected_armies, evt.target); } else { - if (ui.selected_armies.length < ui.selected_fleets.length) + if (ui.selected_armies.length < ui.selected_fleets.length && ui.selected_armies.length < 3) ui.selected_armies.push(here[ui.selected_armies.length]); } } -- cgit v1.2.3