Text for strength, movement and ranged strength in unit tablee replaced with icons - table is now consistently much smaller, and much less bothersome!

This commit is contained in:
Yair Morgenstern 2019-02-14 22:49:46 +02:00
parent 0fab01e393
commit e200e9026f
8 changed files with 416 additions and 411 deletions

View File

@ -394,13 +394,14 @@ All the following are from [the Noun Project](https://thenounproject.com) licenc
* [Skull](https://thenounproject.com/search/?q=Skull&i=1030702) By Vladimir Belochkin for disbanding units
* [Crosshair](https://thenounproject.com/search/?q=crosshairs&i=916030) By Bakunetsu Kaito for selecting enemies to attack
* [City](https://thenounproject.com/search/?q=city&i=571332) By Felix Westphal
* [Fire](https://thenounproject.com/search/?q=Fire&i=96564) By Lloyd Humphreys for
* [Fire](https://thenounproject.com/search/?q=Fire&i=96564) By Lloyd Humphreys for "city being razed" icon
* [Sleep](https://thenounproject.com/search/?q=sleep&i=1760085) By Saeful Muslim
* [Banner](https://thenounproject.com/term/banner/866282/) By Emir Palavan for embarked units
* [Arrow](https://thenounproject.com/term/arrow/18123/) By uzeir syarief for moving between idle units
* [Replace](https://thenounproject.com/search/?q=replace&i=17858) By Mike Rowe, AU
* [Replace](https://thenounproject.com/search/?q=replace&i=17858) By Mike Rowe for switching tiles between cities
* [Resistance](https://thenounproject.com/term/revolution/1315305/) By HeadsOfBirds
* [Viking Hat](https://thenounproject.com/search/?q=pillage&i=185405) By my name is mud
* [Viking Hat](https://thenounproject.com/search/?q=pillage&i=185405) By my name is mud for pillaging improvements
* [Aim](https://thenounproject.com/search/?q=aim&i=2034920) By Kaviashri for ranged strength
# Sound credits

Binary file not shown.

Before

Width:  |  Height:  |  Size: 722 B

After

Width:  |  Height:  |  Size: 506 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 915 B

After

Width:  |  Height:  |  Size: 825 B

File diff suppressed because it is too large Load Diff

Binary file not shown.

Before

Width:  |  Height:  |  Size: 864 KiB

After

Width:  |  Height:  |  Size: 855 KiB

View File

@ -112,6 +112,9 @@
Simplified_Chinese:"远程攻击"
Portuguese:"Força a distancia"
}
"Bombard strength":{ // for displaying city info
}
// Unit actions

View File

@ -83,26 +83,27 @@ class UnitTable(val worldScreen: WorldScreen) : Table(){
unitNameLabel.setText(nameLabelText)
unitDescriptionTable.clear()
unitDescriptionTable.defaults().pad(2f).padRight(5f)
unitDescriptionTable.add("Movement".tr())
unitDescriptionTable.add(unit.getMovementString()).row()
unitDescriptionTable.defaults().pad(2f)
unitDescriptionTable.add(ImageGetter.getStatIcon("Movement")).size(20f)
unitDescriptionTable.add(unit.getMovementString()).padRight(10f)
if (!unit.type.isCivilian()) {
unitDescriptionTable.add("Strength".tr())
unitDescriptionTable.add(unit.baseUnit().strength.toString()).row()
unitDescriptionTable.add(ImageGetter.getStatIcon("Strength")).size(20f)
unitDescriptionTable.add(unit.baseUnit().strength.toString()).padRight(10f)
}
if (unit.baseUnit().rangedStrength!=0) {
unitDescriptionTable.add("Ranged strength".tr())
unitDescriptionTable.add(unit.baseUnit().rangedStrength.toString()).row()
unitDescriptionTable.add(ImageGetter.getStatIcon("RangedStrength")).size(20f)
unitDescriptionTable.add(unit.baseUnit().rangedStrength.toString()).padRight(10f)
}
if (!unit.type.isCivilian()) {
unitDescriptionTable.add("XP")
unitDescriptionTable.add(unit.promotions.XP.toString()+"/"+unit.promotions.xpForNextPromotion()).row()
unitDescriptionTable.add(unit.promotions.XP.toString()+"/"+unit.promotions.xpForNextPromotion())
}
if(unit.isFortified() && unit.getFortificationTurns()>0) {
unitDescriptionTable.row()
unitDescriptionTable.add("Fortification")
unitDescriptionTable.add(""+unit.getFortificationTurns() * 20 + "%")
}
@ -122,7 +123,7 @@ class UnitTable(val worldScreen: WorldScreen) : Table(){
unitDescriptionTable.defaults().pad(2f).padRight(5f)
unitDescriptionTable.add("Strength".tr())
unitDescriptionTable.add(CityCombatant(city).getCityStrength().toString()).row()
unitDescriptionTable.add("Ranged Strength".tr())
unitDescriptionTable.add("Bombard strength".tr())
unitDescriptionTable.add(CityCombatant(city).getAttackingStrength().toString()).row()
selectedUnitHasChanged = true