From cc1ae034d39d4c57f9ea772c318e851b0aeaffb2 Mon Sep 17 00:00:00 2001 From: Yair Morgenstern Date: Sat, 11 Apr 2020 22:26:12 +0300 Subject: [PATCH] Fixed "Trade is no longer valid" problem --- core/src/com/unciv/logic/trade/TradeEvaluation.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/com/unciv/logic/trade/TradeEvaluation.kt b/core/src/com/unciv/logic/trade/TradeEvaluation.kt index cb956acf9d..36e7ea1f71 100644 --- a/core/src/com/unciv/logic/trade/TradeEvaluation.kt +++ b/core/src/com/unciv/logic/trade/TradeEvaluation.kt @@ -25,7 +25,7 @@ class TradeEvaluation{ fun hasResource(tradeOffer: TradeOffer): Boolean { val resourcesByName = offerer.getCivResourcesByName() - return resourcesByName.containsKey(tradeOffer.name) && resourcesByName[tradeOffer.name]!! >= tradeOffer.amount + return resourcesByName.containsKey(tradeOffer.name) && resourcesByName[tradeOffer.name]!! >= 0 } when(tradeOffer.type){