mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-29 15:01:09 -04:00
Better Resource order in empire overview screen (#2577)
This commit is contained in:
parent
2b3a9c14bf
commit
a940eda4a9
@ -542,8 +542,11 @@ class EmpireOverviewScreen(private val viewingPlayer:CivilizationInfo, private v
|
|||||||
|
|
||||||
// First row of table has all the icons
|
// First row of table has all the icons
|
||||||
resourcesTable.add()
|
resourcesTable.add()
|
||||||
|
// Order of source ResourceSupplyList: by tiles, enumerating the map in that spiral pattern
|
||||||
|
// UI should not surprise player, thus we need a deterministic and guessable order
|
||||||
val resources = resourceDrilldown.map { it.resource }
|
val resources = resourceDrilldown.map { it.resource }
|
||||||
.filter { it.resourceType!=ResourceType.Bonus }.distinct().sortedBy { it.resourceType }
|
.filter { it.resourceType!=ResourceType.Bonus }.distinct()
|
||||||
|
.sortedWith(compareBy( { it.resourceType }, { it.name.tr() } ))
|
||||||
|
|
||||||
var visibleLabel: Label? = null
|
var visibleLabel: Label? = null
|
||||||
for(resource in resources) {
|
for(resource in resources) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user