mirror of
https://github.com/yairm210/Unciv.git
synced 2025-01-10 07:16:54 +07:00
AIs don't add double agreements to counteroffers
This commit is contained in:
parent
e11a32bb41
commit
3d93dafb13
@ -139,6 +139,8 @@ object NextTurnAutomation {
|
|||||||
continue // For example resources gained by trade or CS
|
continue // For example resources gained by trade or CS
|
||||||
if (offer.type == TradeType.City)
|
if (offer.type == TradeType.City)
|
||||||
continue // Players generally don't want to give up their cities, and they might misclick
|
continue // Players generally don't want to give up their cities, and they might misclick
|
||||||
|
if (offer.type == TradeType.Agreement && tradeLogic.currentTrade.theirOffers.contains(offer))
|
||||||
|
continue // So you don't get double offers of open borders etc.
|
||||||
val value = evaluation.evaluateBuyCost(offer, civInfo, otherCiv)
|
val value = evaluation.evaluateBuyCost(offer, civInfo, otherCiv)
|
||||||
if (value > 0)
|
if (value > 0)
|
||||||
potentialAsks[offer] = value
|
potentialAsks[offer] = value
|
||||||
|
Loading…
Reference in New Issue
Block a user