Double trades fix + Diplomacy screen layout fix (#8896)

This commit is contained in:
Gualdimar
2023-03-14 20:41:42 +02:00
committed by GitHub
parent 0a9814e3b8
commit 3bbb3a016c
2 changed files with 2 additions and 2 deletions

View File

@ -653,7 +653,7 @@ object NextTurnAutomation {
}) {
val relationshipLevel = civInfo.getDiplomacyManager(otherCiv).relationshipLevel()
if (relationshipLevel <= RelationshipLevel.Enemy)
if (relationshipLevel <= RelationshipLevel.Enemy || otherCiv.tradeRequests.any { it.requestingCiv == civInfo.civName })
continue
val trades = potentialLuxuryTrades(civInfo, otherCiv)

View File

@ -949,7 +949,7 @@ class DiplomacyScreen(
* _Caller is responsible to not exceed this **including its own padding**_
*/
// Note breaking the rule above will squeeze the leftSideScroll to the left - cumulatively.
internal fun getTradeColumnsWidth() = (stage.width - leftSideScroll.width - 3f) / 2 // 3 for SplitPane handle
internal fun getTradeColumnsWidth() = (stage.width * 0.8f - 3f) / 2 // 3 for SplitPane handle
override fun resize(width: Int, height: Int) {
super.resize(width, height)