diff --git a/android/assets/jsons/Tutorials_English.json b/android/assets/jsons/Tutorials_English.json index 2247e2596b..6007c58d2e 100644 --- a/android/assets/jsons/Tutorials_English.json +++ b/android/assets/jsons/Tutorials_English.json @@ -301,10 +301,9 @@ CanEmbark:[ [ - "Your land units can now embark!", - "Siege units are extremely powerful against cities, but need to be Set Up before they can attack.", - "Once your siege unit is set up, it can attack from the current tile,", - " but once moved to another tile, it will need to be set up again." + "Your land units can now embark, allowing them to traverse water tiles!", + "Entering or leaving water takes the entire turn.", + "Units are defenseless while embarked, so be careful!" ] ] diff --git a/android/build.gradle b/android/build.gradle index ea2969a898..c94cf7668f 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -21,8 +21,8 @@ android { applicationId "com.unciv.game" minSdkVersion 14 targetSdkVersion 26 - versionCode 161 - versionName "2.10.2" + versionCode 163 + versionName "2.10.3" } buildTypes { release { diff --git a/core/src/com/unciv/ui/cityscreen/BuildingsTable.kt b/core/src/com/unciv/ui/cityscreen/BuildingsTable.kt index 375ecdfa0a..b8a19192ee 100644 --- a/core/src/com/unciv/ui/cityscreen/BuildingsTable.kt +++ b/core/src/com/unciv/ui/cityscreen/BuildingsTable.kt @@ -82,7 +82,7 @@ class BuildingsTable(private val cityScreen: CityScreen) : Table() { add(specialistBuildingsExpander).row() // specialist allocation - addSpecialistAllocation(skin, specialistBuildings, cityInfo) + addSpecialistAllocation(skin, cityInfo) } if (!others.isEmpty()) { @@ -96,7 +96,7 @@ class BuildingsTable(private val cityScreen: CityScreen) : Table() { pack() } - private fun addSpecialistAllocation(skin: Skin, specialistBuildings: MutableList, cityInfo: CityInfo) { + private fun addSpecialistAllocation(skin: Skin, cityInfo: CityInfo) { val specialistAllocationExpander = ExpanderTab("Specialist allocation", skin) specialistAllocationExpander.innerTable.defaults().pad(5f) @@ -104,17 +104,17 @@ class BuildingsTable(private val cityScreen: CityScreen) : Table() { val currentSpecialists = cityInfo.population.specialists.toHashMap() val maximumSpecialists = cityInfo.population.getMaxSpecialists() - for (entry in maximumSpecialists.toHashMap()) { - if (entry.value == 0f) continue - val stat = entry.key + for (statToMaximumSpecialist in maximumSpecialists.toHashMap()) { + if (statToMaximumSpecialist.value == 0f) continue + val stat = statToMaximumSpecialist.key // these two are conflictingly named compared to above... - val assignedSpecialists = currentSpecialists[entry.key]!!.toInt() - val maxSpecialists = entry.value.toInt() + val assignedSpecialists = currentSpecialists[statToMaximumSpecialist.key]!!.toInt() + val maxSpecialists = statToMaximumSpecialist.value.toInt() if (assignedSpecialists > 0) { val unassignButton = TextButton("-", skin) unassignButton.label.setFontSize(24) unassignButton.onClick { - cityInfo.population.specialists.add(entry.key, -1f) + cityInfo.population.specialists.add(statToMaximumSpecialist.key, -1f) cityInfo.cityStats.update() cityScreen.update() } @@ -131,7 +131,7 @@ class BuildingsTable(private val cityScreen: CityScreen) : Table() { val assignButton = TextButton("+", skin) assignButton.label.setFontSize(24) assignButton.onClick { - cityInfo.population.specialists.add(entry.key, +1f) + cityInfo.population.specialists.add(statToMaximumSpecialist.key, +1f) cityInfo.cityStats.update() cityScreen.update() } diff --git a/core/src/com/unciv/ui/tilegroups/TileGroup.kt b/core/src/com/unciv/ui/tilegroups/TileGroup.kt index a3db6a7a6e..83af70b3b9 100644 --- a/core/src/com/unciv/ui/tilegroups/TileGroup.kt +++ b/core/src/com/unciv/ui/tilegroups/TileGroup.kt @@ -119,8 +119,8 @@ open class TileGroup(var tileInfo: TileInfo) : Group() { updateCityImage() updateTileColor(isViewable) - updateResourceImage(isViewable,showResourcesAndImprovements) - updateImprovementImage(isViewable,showResourcesAndImprovements) + updateResourceImage(showResourcesAndImprovements) + updateImprovementImage(showResourcesAndImprovements) civilianUnitImage = newUnitImage(tileInfo.civilianUnit, civilianUnitImage, isViewable, -20f) @@ -272,7 +272,7 @@ open class TileGroup(var tileInfo: TileInfo) : Group() { } } - private fun updateImprovementImage(viewable: Boolean, showResourcesAndImprovements: Boolean) { + private fun updateImprovementImage(showResourcesAndImprovements: Boolean) { if (improvementImage != null) { improvementImage!!.remove() improvementImage = null @@ -293,7 +293,7 @@ open class TileGroup(var tileInfo: TileInfo) : Group() { } } - private fun updateResourceImage(viewable: Boolean, showResourcesAndImprovements: Boolean) { + private fun updateResourceImage(showResourcesAndImprovements: Boolean) { val shouldDisplayResource = showResourcesAndImprovements && tileInfo.hasViewableResource(tileInfo.tileMap.gameInfo.getPlayerCivilization()) @@ -365,9 +365,9 @@ open class TileGroup(var tileInfo: TileInfo) : Group() { fun showCircle(color: Color) { circleImage.isVisible = true - val color = color.cpy() - color.a = 0.3f - circleImage.color = color + val colorCopy = color.cpy() + colorCopy.a = 0.3f + circleImage.color = colorCopy } fun hideCircle() {