From c823989c39c3187ab552ce71b28840a1ffc90d76 Mon Sep 17 00:00:00 2001 From: Yair Morgenstern Date: Sun, 18 Jun 2023 01:03:20 +0300 Subject: [PATCH] Reverted BFS changes, since they caused significant performance degradation --- .../unciv/logic/automation/civilization/NextTurnAutomation.kt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt b/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt index 5e7a741ffd..dbd7d096d5 100644 --- a/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt +++ b/core/src/com/unciv/logic/automation/civilization/NextTurnAutomation.kt @@ -384,9 +384,7 @@ object NextTurnAutomation { val cityWithLeastCostToBuy = highlyDesirableTile.value.minBy { it.getCenterTile().aerialDistanceTo(highlyDesirableTile.key) } - val bfs = BFS(cityWithLeastCostToBuy.getCenterTile(), - // Give higher priority on the way to intermediate tiles with higher ranking stats - { Automation.rankStatsValue(it.stats.getTileStats(cityWithLeastCostToBuy, civInfo), civInfo).toInt() }) + val bfs = BFS(cityWithLeastCostToBuy.getCenterTile()) { it.getOwner() == null || it.getOwner() == civInfo }