mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-27 22:06:05 -04:00
Added Hubble Space Telescope wonder, Stable unique ability
Added missing translations
This commit is contained in:
parent
2df64861d1
commit
49ed7570f8
@ -206,7 +206,7 @@ All the following are from [the Noun Project](https://thenounproject.com) licenc
|
|||||||
* [Nuclear Plant](https://thenounproject.com/term/nuclear-plant/1132340/) By Andrejs Kirma
|
* [Nuclear Plant](https://thenounproject.com/term/nuclear-plant/1132340/) By Andrejs Kirma
|
||||||
|
|
||||||
### Future Era
|
### Future Era
|
||||||
|
* [Hubble Telescope](https://thenounproject.com/search/?q=hubble%20space&i=445502) By Scott Lewis for Hubble Space Telescope
|
||||||
* [Missile](https://thenounproject.com/term/missile/799922/) By ProSymbols for SS Booster
|
* [Missile](https://thenounproject.com/term/missile/799922/) By ProSymbols for SS Booster
|
||||||
* [Rocket](https://thenounproject.com/term/rocket/937173/) By BomSymbols for SS Cockpit
|
* [Rocket](https://thenounproject.com/term/rocket/937173/) By BomSymbols for SS Cockpit
|
||||||
* [Engine](https://thenounproject.com/term/engine/1877958/) By Andre for SS Engine
|
* [Engine](https://thenounproject.com/term/engine/1877958/) By Andre for SS Engine
|
||||||
|
BIN
android/Images/BuildingIcons/Hubble Space Telescope.png
Normal file
BIN
android/Images/BuildingIcons/Hubble Space Telescope.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.4 KiB |
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Before Width: | Height: | Size: 844 KiB After Width: | Height: | Size: 846 KiB |
@ -133,6 +133,7 @@
|
|||||||
requiredNearbyImprovedResources:["Horses","Sheep","Cattle"]
|
requiredNearbyImprovedResources:["Horses","Sheep","Cattle"]
|
||||||
resourceBonusStats:{production:1},
|
resourceBonusStats:{production:1},
|
||||||
hurryCostModifier:25,
|
hurryCostModifier:25,
|
||||||
|
uniques:["+15% Production when building Mounted Units in this city"]
|
||||||
requiredTech:"Horseback Riding"
|
requiredTech:"Horseback Riding"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -627,6 +628,15 @@
|
|||||||
|
|
||||||
// Future Era
|
// Future Era
|
||||||
|
|
||||||
|
{
|
||||||
|
name:"Hubble Space Telescope",
|
||||||
|
cost:1250,
|
||||||
|
isWonder:true,
|
||||||
|
providesFreeBuilding: "Spaceship Factory",
|
||||||
|
uniques:["2 free great scientists appear",
|
||||||
|
"Increases production of spaceship parts by 25%"],
|
||||||
|
requiredTech:"Satellites"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name:"SS Cockpit",
|
name:"SS Cockpit",
|
||||||
requiredResource:"Aluminum",
|
requiredResource:"Aluminum",
|
||||||
|
@ -2616,6 +2616,7 @@
|
|||||||
Simplified_Chinese:"电子"
|
Simplified_Chinese:"电子"
|
||||||
Portuguese:"Eletronicos"
|
Portuguese:"Eletronicos"
|
||||||
}
|
}
|
||||||
|
"Ballistics":{}
|
||||||
"Mass Media":{
|
"Mass Media":{
|
||||||
Italian:"Mass media"
|
Italian:"Mass media"
|
||||||
Russian:"СМИ"
|
Russian:"СМИ"
|
||||||
@ -4231,6 +4232,8 @@
|
|||||||
Simplified_Chinese:"马厩"
|
Simplified_Chinese:"马厩"
|
||||||
Portuguese:"Estabulos"
|
Portuguese:"Estabulos"
|
||||||
}
|
}
|
||||||
|
"+15% Production when building Mounted Units in this city":{}
|
||||||
|
|
||||||
"Circus Maximus":{
|
"Circus Maximus":{
|
||||||
Italian:"Circo Maximus"
|
Italian:"Circo Maximus"
|
||||||
Russian:"Цирк Максимус"
|
Russian:"Цирк Максимус"
|
||||||
@ -4816,6 +4819,9 @@
|
|||||||
Portuguese:"Provem 1 felicade por política social"
|
Portuguese:"Provem 1 felicade por política social"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
"Statue of Liberty":{}
|
||||||
|
"+1 Production from specialists":{}
|
||||||
|
|
||||||
"Medical Lab":{
|
"Medical Lab":{
|
||||||
Italian:"Laboratorio medico"
|
Italian:"Laboratorio medico"
|
||||||
Russian:"Медицинская лаборатория"
|
Russian:"Медицинская лаборатория"
|
||||||
@ -4945,6 +4951,11 @@
|
|||||||
Simplified_Chinese:"宇宙飞船的部件"
|
Simplified_Chinese:"宇宙飞船的部件"
|
||||||
Portuguese:"Parte de Nave Espacial"
|
Portuguese:"Parte de Nave Espacial"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
"Hubble Space Telescope":{}
|
||||||
|
"2 free great scientists appear":{}
|
||||||
|
"Increases production of spaceship parts by 25%":{}
|
||||||
|
|
||||||
"SS Booster":{ //no translation that I know of
|
"SS Booster":{ //no translation that I know of
|
||||||
Italian:"Propulsore dell'astronave"
|
Italian:"Propulsore dell'astronave"
|
||||||
Spanish:"Potenciador (Nave espacial)"
|
Spanish:"Potenciador (Nave espacial)"
|
||||||
|
@ -6,6 +6,7 @@ import com.unciv.logic.map.RoadStatus
|
|||||||
import com.unciv.models.gamebasics.Building
|
import com.unciv.models.gamebasics.Building
|
||||||
import com.unciv.models.gamebasics.GameBasics
|
import com.unciv.models.gamebasics.GameBasics
|
||||||
import com.unciv.models.gamebasics.unit.BaseUnit
|
import com.unciv.models.gamebasics.unit.BaseUnit
|
||||||
|
import com.unciv.models.gamebasics.unit.UnitType
|
||||||
import com.unciv.models.stats.Stat
|
import com.unciv.models.stats.Stat
|
||||||
import com.unciv.models.stats.Stats
|
import com.unciv.models.stats.Stats
|
||||||
|
|
||||||
@ -230,10 +231,23 @@ class CityStats {
|
|||||||
return stats
|
return stats
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun getStatPercentBonusesFromWonders(): Stats {
|
private fun getStatPercentBonusesFromBuildings(): Stats {
|
||||||
val stats = Stats()
|
val stats = Stats()
|
||||||
val civUniques = cityInfo.civInfo.getBuildingUniques()
|
val civUniques = cityInfo.civInfo.getBuildingUniques()
|
||||||
if (civUniques.contains("Culture in all cities increased by 25%")) stats.culture += 25f
|
if (civUniques.contains("Culture in all cities increased by 25%")) stats.culture += 25f
|
||||||
|
|
||||||
|
val currentConstruction = cityInfo.cityConstructions.getCurrentConstruction()
|
||||||
|
if(currentConstruction is Building && currentConstruction.uniques.contains("Spaceship part")){
|
||||||
|
if(civUniques.contains("Increases production of spaceship parts by 25%"))
|
||||||
|
stats.production += 25
|
||||||
|
if(cityInfo.getBuildingUniques().contains("Increases production of spaceship parts by 50%"))
|
||||||
|
stats.production += 50
|
||||||
|
}
|
||||||
|
|
||||||
|
if(currentConstruction is BaseUnit && currentConstruction.unitType==UnitType.Mounted
|
||||||
|
&& cityInfo.getBuildingUniques().contains("+15% Production when building Mounted Units in this city"))
|
||||||
|
stats.production += 15
|
||||||
|
|
||||||
return stats
|
return stats
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -295,7 +309,7 @@ class CityStats {
|
|||||||
newStatPercentBonusList["Golden Age"]=getStatPercentBonusesFromGoldenAge(cityInfo.civInfo.goldenAges.isGoldenAge())
|
newStatPercentBonusList["Golden Age"]=getStatPercentBonusesFromGoldenAge(cityInfo.civInfo.goldenAges.isGoldenAge())
|
||||||
newStatPercentBonusList["Policies"]=getStatPercentBonusesFromPolicies(civInfo.policies.adoptedPolicies, cityInfo.cityConstructions)
|
newStatPercentBonusList["Policies"]=getStatPercentBonusesFromPolicies(civInfo.policies.adoptedPolicies, cityInfo.cityConstructions)
|
||||||
// from wonders - Culture in all cities increased by 25%
|
// from wonders - Culture in all cities increased by 25%
|
||||||
newStatPercentBonusList["Wonders"]=getStatPercentBonusesFromWonders()
|
newStatPercentBonusList["Buildings"]=getStatPercentBonusesFromBuildings()
|
||||||
newStatPercentBonusList["Railroad"]=getStatPercentBonusesFromRailroad()
|
newStatPercentBonusList["Railroad"]=getStatPercentBonusesFromRailroad()
|
||||||
newStatPercentBonusList["Marble"]=getStatPercentBonusesFromMarble()
|
newStatPercentBonusList["Marble"]=getStatPercentBonusesFromMarble()
|
||||||
newStatPercentBonusList["Computers"]=getStatPercentBonusesFromComputers()
|
newStatPercentBonusList["Computers"]=getStatPercentBonusesFromComputers()
|
||||||
|
@ -390,10 +390,9 @@ class CivilizationInfo {
|
|||||||
notifications.add(Notification(text, location,color))
|
notifications.add(Notification(text, location,color))
|
||||||
}
|
}
|
||||||
|
|
||||||
fun addGreatPerson(greatPerson: String) {
|
fun addGreatPerson(greatPerson: String, city:CityInfo = cities.getRandom()) {
|
||||||
val randomCity = cities.getRandom()
|
placeUnitNearTile(city.location, greatPerson)
|
||||||
placeUnitNearTile(cities.getRandom().location, greatPerson)
|
addNotification("A [$greatPerson] has been born!".tr(), city.location, Color.GOLD)
|
||||||
addNotification("A [$greatPerson] has been born!".tr(), randomCity.location, Color.GOLD)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun placeUnitNearTile(location: Vector2, unitName: String): MapUnit {
|
fun placeUnitNearTile(location: Vector2, unitName: String): MapUnit {
|
||||||
|
@ -239,8 +239,12 @@ class Building : NamedStats(), IConstruction{
|
|||||||
|
|
||||||
when {
|
when {
|
||||||
"Empire enters golden age" in uniques -> civInfo.goldenAges.enterGoldenAge()
|
"Empire enters golden age" in uniques -> civInfo.goldenAges.enterGoldenAge()
|
||||||
"Free Great Artist Appears" in uniques -> civInfo.addGreatPerson("Great Artist")
|
"Free Great Artist Appears" in uniques -> civInfo.addGreatPerson("Great Artist", construction.cityInfo)
|
||||||
"Free great scientist appears" in uniques -> civInfo.addGreatPerson("Great Scientist")
|
"Free great scientist appears" in uniques -> civInfo.addGreatPerson("Great Scientist", construction.cityInfo)
|
||||||
|
"2 free great scientists appear" in uniques -> {
|
||||||
|
civInfo.addGreatPerson("Great Scientist", construction.cityInfo)
|
||||||
|
civInfo.addGreatPerson("Great Scientist", construction.cityInfo)
|
||||||
|
}
|
||||||
"Provides 2 free workers" in uniques -> {
|
"Provides 2 free workers" in uniques -> {
|
||||||
civInfo.placeUnitNearTile(construction.cityInfo.location, "Worker")
|
civInfo.placeUnitNearTile(construction.cityInfo.location, "Worker")
|
||||||
civInfo.placeUnitNearTile(construction.cityInfo.location, "Worker")
|
civInfo.placeUnitNearTile(construction.cityInfo.location, "Worker")
|
||||||
|
@ -33,17 +33,17 @@ class LoadScreen : PickerScreen() {
|
|||||||
topTable.add(saveTable)
|
topTable.add(saveTable)
|
||||||
val saves = GameSaver().getSaves()
|
val saves = GameSaver().getSaves()
|
||||||
rightSideButton.setText("Load game".tr())
|
rightSideButton.setText("Load game".tr())
|
||||||
saves.forEach {
|
for (save in saves) {
|
||||||
val textButton = TextButton(it,skin)
|
val textButton = TextButton(save,skin)
|
||||||
textButton.onClick {
|
textButton.onClick {
|
||||||
selectedSave=it
|
selectedSave=save
|
||||||
|
|
||||||
var textToSet = it
|
var textToSet = save
|
||||||
|
|
||||||
val savedAt = Date(GameSaver().getSave(it).lastModified())
|
val savedAt = Date(GameSaver().getSave(save).lastModified())
|
||||||
textToSet+="\n{Saved at}: ".tr()+ SimpleDateFormat("dd-MM-yy HH.mm").format(savedAt)
|
textToSet+="\n{Saved at}: ".tr()+ SimpleDateFormat("dd-MM-yy HH.mm").format(savedAt)
|
||||||
try{
|
try{
|
||||||
val game = GameSaver().loadGame(it)
|
val game = GameSaver().loadGame(save)
|
||||||
val playerCivNames = game.civilizations.filter { it.isPlayerCivilization() }.joinToString{it.civName.tr()}
|
val playerCivNames = game.civilizations.filter { it.isPlayerCivilization() }.joinToString{it.civName.tr()}
|
||||||
textToSet+="\n"+playerCivNames+
|
textToSet+="\n"+playerCivNames+
|
||||||
", "+game.difficulty.tr()+", {Turn} ".tr()+game.turns
|
", "+game.difficulty.tr()+", {Turn} ".tr()+game.turns
|
||||||
@ -51,7 +51,7 @@ class LoadScreen : PickerScreen() {
|
|||||||
textToSet+="\n{Could not load game}!".tr()
|
textToSet+="\n{Could not load game}!".tr()
|
||||||
}
|
}
|
||||||
descriptionLabel.setText(textToSet)
|
descriptionLabel.setText(textToSet)
|
||||||
rightSideButton.setText("Load [$it]".tr())
|
rightSideButton.setText("Load [$save]".tr())
|
||||||
rightSideButton.enable()
|
rightSideButton.enable()
|
||||||
deleteSaveButton.enable()
|
deleteSaveButton.enable()
|
||||||
deleteSaveButton.color= Color.RED
|
deleteSaveButton.color= Color.RED
|
||||||
|
Loading…
x
Reference in New Issue
Block a user