From 6b4003311b60c53f3a75250c9882a95f76276c69 Mon Sep 17 00:00:00 2001 From: WhoIsJohannes <126110113+WhoIsJohannes@users.noreply.github.com> Date: Tue, 4 Apr 2023 22:42:18 +0200 Subject: [PATCH] Don't buy tiles in the very early game. (#9117) --- .../logic/automation/civilization/NextTurnAutomation.kt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt b/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt index 72185c08c1..8ed08a0d3e 100644 --- a/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt +++ b/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt @@ -336,6 +336,12 @@ object NextTurnAutomation { private fun maybeBuyCityTiles(civInfo: Civilization) { if (civInfo.gold <= 0) return + // Don't buy tiles in the very early game. It is unlikely that we already have the required + // tech, the necessary worker and that there is a reasonable threat from another player to + // grab the tile. We could also check all that, but it would require a lot of cycles each + // turn and this is probably a good approximation. + if (civInfo.gameInfo.turns < (civInfo.gameInfo.speed.scienceCostModifier * 20).toInt()) + return val highlyDesirableTiles: SortedMap> = TreeMap( compareByDescending { it?.naturalWonder != null }