From 4b4473049cd996f0c901002bd041d75fae4dac36 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Mon, 24 Jan 2022 22:42:34 +0100 Subject: Count at most 4 sunk frigates for Tripolitan score. --- rules.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'rules.js') diff --git a/rules.js b/rules.js index 06445a9..4456bf4 100644 --- a/rules.js +++ b/rules.js @@ -2923,7 +2923,7 @@ exports.is_checkpoint = (a, b) => a.season !== b.season; exports.view = function(state, current) { game = state; - let tr_score = count_american_frigates(TRIPOLITAN_SUPPLY) * 3 + game.tr.gold; + let tr_score = Math.min(count_american_frigates(TRIPOLITAN_SUPPLY), 4) * 3 + game.tr.gold; let view = { log: game.log, -- cgit v1.2.3