mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-27 22:06:05 -04:00
Merge remote-tracking branch 'upstream/master'
update
This commit is contained in:
commit
ce892d20a2
@ -573,7 +573,7 @@
|
||||
outerColor:[54,72,72],
|
||||
innerColor:[246,205,137],
|
||||
uniqueName:"The Great Warpath"
|
||||
unique:"All units move through Forest and Jungle tiles in friendly territory as if it is Road. These tiles can be used to establish City Connections upon researching the Wheel.",
|
||||
unique: "All units move through Forest and Jungle Tiles in friendly territory as if they have roads. These tiles can be used to establish City Connections upon researching the Wheel.",
|
||||
cities:["Onoondaga","Osininka","Grand River","Akwesasme","Buffalo Creek","Brantford","Montreal","Genesse River",
|
||||
"Canandaigua Lake","Lake Simcoe","Salamanca","Gowanda","Cuba","Akron","Kanesatake","Ganienkeh","Cayuga Castle",
|
||||
"Chondote","Canajoharie","Nedrow","Oneida Lake","Kanonwalohale","Green Bay","Southwold","Mohawk Valley",
|
||||
|
@ -145,7 +145,32 @@
|
||||
improvingTechStats:{gold:1}
|
||||
},
|
||||
|
||||
//Civilization unique improvements
|
||||
/*
|
||||
{
|
||||
name:"Moai",
|
||||
uniqueTo:"Polynesia",
|
||||
culture:1,
|
||||
turnsToBuild:4,
|
||||
improvingTech:"Construction",
|
||||
uniques:["+1 additional Culture for each adjacent Moai","+1 Gold after researching Flight"],
|
||||
terrainsCanBeBuiltOn:["Hill"],
|
||||
//It can be colored in orange
|
||||
},
|
||||
{
|
||||
name:"Terrace Farm",
|
||||
uniqueTo:"Inca",
|
||||
food:1,
|
||||
turnsToBuild:4,
|
||||
improvingTech:"Construction",
|
||||
uniques:["+1 Food for each adjacent Mountain","+1 additional Food with Fertilizer and no fresh water"],
|
||||
terrainsCanBeBuiltOn:["Plains","Grassland","Desert","Tundra"],
|
||||
//It can be colored in lemon
|
||||
//Cannot improve a resource
|
||||
},
|
||||
*/
|
||||
|
||||
{ name:"Ancient ruins" },
|
||||
{ name:"City ruins" },
|
||||
{ name:"Barbarian encampment" },
|
||||
]
|
||||
]
|
||||
|
@ -932,6 +932,10 @@
|
||||
Polish:"Porcelanowa wieża"
|
||||
}
|
||||
|
||||
"'Things always seem fairer when we look back at them, and it is out of that inaccessible tower of the past that Longing leans and beckons.' - James Russell Lowell":{
|
||||
Italian:"'Le cose sembrano sempre più belle quando ci voltiamo indietro per guardarle, ed è dall'inaccessibile torre del passato che la nostalgia si protende e chiama.' - James Russel Lowell"
|
||||
}
|
||||
|
||||
"Free great scientist appears":{
|
||||
Spanish:"Aparece una Gran Científico gratis"
|
||||
Italian:"Appare un Grande Scienziato"
|
||||
@ -1004,6 +1008,10 @@
|
||||
Polish:"Kaplica Sykstyńska"
|
||||
}
|
||||
|
||||
"'I live and love in God's peculiar light.' - Michelangelo Buonarroti":{
|
||||
Italian:"'Vivo e amo sotto la peculiare luce di Dio.' - Michelangelo Buonarroti"
|
||||
}
|
||||
|
||||
"Culture in all cities increased by 25%":{
|
||||
Italian:"+25% cultura in ogni città"
|
||||
Russian:"Увеличивает прирост культуры на 25% во всех городах"
|
||||
@ -1063,6 +1071,10 @@
|
||||
Polish:"Zakazane miasto"
|
||||
}
|
||||
|
||||
"'Most of us can, as we choose, make of this world either a palace or a prison' - John Lubbock":{
|
||||
Italian:"'La maggior parte di noi può, a sua volontà, fare di questo mondo un palazzo o una prigione.' - John Lubbock"
|
||||
}
|
||||
|
||||
"Unhappiness from population decreased by 10%":{
|
||||
Italian:"-10% infelicità dalla popolazione"
|
||||
Russian:"Снижает недовольство от населения на 10%"
|
||||
@ -1099,6 +1111,10 @@
|
||||
Russian:"Пизанская башня"
|
||||
}
|
||||
|
||||
"'Don't clap too hard - it's a very old building.' - John Osbourne":{
|
||||
Italian:"'Non applaudite troppo forte - è un edificio molto vecchio.' - John Osborne"
|
||||
}
|
||||
|
||||
"Free Great Person":{
|
||||
Italian:"Ottieni un Grande Personaggio gratuito"
|
||||
Romanian:"Persoană mare gratuită"
|
||||
@ -1131,6 +1147,10 @@
|
||||
Russian:"Замок Химэдзи"
|
||||
}
|
||||
|
||||
"'Bushido is realized in the presence of death. This means choosing death whenever there is a choice between life and death. There is no other reasoning.' - Yamamoto Tsunetomo":{
|
||||
Italian:"'Il Bushido si realizza in presenza della morte. Significa, ogni volta che c'è una scelta tra la vita e la morte, scegliere la seconda. Non c'è alcun altro ragionamento' - Yamamoto Tsunetomo"
|
||||
}
|
||||
|
||||
"+15% combat strength for units fighting in friendly territory":{
|
||||
Italian:"+15% Forza per le unità che combattono in territorio amico"
|
||||
Simplified_Chinese:"单位在境内+15%战斗力"
|
||||
@ -1151,6 +1171,10 @@
|
||||
German:"Taj Mahal"
|
||||
Polish:"Tadź Mahal"
|
||||
}
|
||||
|
||||
"'The Taj Mahal rises above the banks of the river like a solitary tear suspended on the cheek of time.' - Rabindranath Tagore":{
|
||||
Italian:"'Il Taj Mahal sorge sulle rive del fiume come una lacrima solitaria sospesa sulla guancia del tempo.' - Rabindranath Tagore"
|
||||
}
|
||||
|
||||
"Empire enters golden age":{
|
||||
Italian:"L'impero entra nell'Età dell'Oro"
|
||||
@ -1221,6 +1245,10 @@
|
||||
Polish:"Luwr"
|
||||
}
|
||||
|
||||
"'Every genuine work of art has as much reason for being as the earth and the sun' - Ralph Waldo Emerson":{
|
||||
Italian:"'Ogni opera d'arte genuina ha tanta ragione d'esistere quanto la terra e il sole.' - Ralph Waldo Emerson"
|
||||
}
|
||||
|
||||
"Free Great Artist Appears":{
|
||||
Italian:"Appare un Grande Artista gratuito"
|
||||
Russian:"Появляется бесплатный Великий Художник"
|
||||
@ -1339,6 +1367,10 @@
|
||||
Russian:"Биг Бен"
|
||||
}
|
||||
|
||||
"'To achieve great things, two things are needed: a plan, and not quite enough time.' - Leonard Bernstein":{
|
||||
Italian:"'Per ottenere grandi risultati servono due cose: un piano e un sacco di tempo.' - Leonard Bernstein"
|
||||
}
|
||||
|
||||
"-15% to purchasing items in cities":{
|
||||
Italian:"-15% costi in Oro per l'acquisto di unità ed edifici nelle Città"
|
||||
Simplified_Chinese:"所有城市购买建造项目所需的金钱花费-15%"
|
||||
@ -1359,6 +1391,10 @@
|
||||
Polish:"Statua Chrystusa Zbawiciela"
|
||||
}
|
||||
|
||||
"'Come to me, all who labor and are heavy burdened, and I will give you rest.' - New Testament, Matthew 11:28":{
|
||||
Italian:"'Venite a me, voi tutti che siete affaticati e oppressi, e io vi ristorerò.' - Matteo 11:28"
|
||||
}
|
||||
|
||||
"Culture cost of adopting new Policies reduced by 10%":{
|
||||
Italian:"-10% costo in Cultura per ogni nuova politica"
|
||||
Russian:"Колличество культуры для принятия новых общественных институтов -10%"
|
||||
@ -1382,6 +1418,10 @@
|
||||
Polish:"Kreml"
|
||||
}
|
||||
|
||||
"'The Law is a fortress on a hill that armies cannot take or floods wash away.' –- The Prophet Muhammed":{
|
||||
Italian:"'La Legge è una fortezza su una collina che gli eserciti non possono catturare e le inondazioni non possono spazzare via. - Il profeta Maometto"
|
||||
}
|
||||
|
||||
"Defensive buildings in all cities are 25% more effective":{
|
||||
Italian:"+25% efficacia delle strutture difensive in tutte le città"
|
||||
Simplified_Chinese:"所有城市防御建筑建造速度+25%"
|
||||
@ -1398,6 +1438,10 @@
|
||||
Russian:"Замок Нойшванштайн"
|
||||
}
|
||||
|
||||
"'...the location is one of the most beautiful to be found, holy and unapproachable, a worthy temple for the divine friend who has brought salvation and true blessing to the world.' - King Ludwig II of Bavaria":{
|
||||
Italian:"'...la posizione è una delle più belle che si possano trovare, sacra e inaccessibile, degno tempio per l'amico divino che ha portato salvezza e vera benedizione a tutto il mondo.' - Re Ludovico II di Baviera"
|
||||
}
|
||||
|
||||
"+1 happiness, +2 culture and +3 gold from every Castle":{
|
||||
Italian:"+1 Felicità, +2 Cultura e +3 Oro per ogni Castello posseduto"
|
||||
Simplified_Chinese:"每一座城堡+3金钱、+2文化和+1快乐"
|
||||
@ -1442,6 +1486,10 @@
|
||||
Polish:"Wieża Eiffla"
|
||||
}
|
||||
|
||||
"'We live only to discover beauty, all else is a form of waiting' - Kahlil Gibran":{
|
||||
Italian:"'Chi può pensare che, siccome siamo ingegneri, la bellezza non ci preoccupi, o che non cerchiamo di costruire strutture belle oltre che solide e durature?' - Gustave Alexandre Eiffel"
|
||||
}
|
||||
|
||||
"Provides 1 happiness per social policy":{
|
||||
Italian:"+1 Felicità per ogni politica sociale"
|
||||
Russian:"Обеспечивает 1 счастье за каждый общественный институт"
|
||||
@ -1464,6 +1512,10 @@
|
||||
Russian:"Статуя Свободы"
|
||||
}
|
||||
|
||||
"'Give me your tired, your poor, your huddled masses yearning to breathe free, the wretched refuse of your teeming shore. Send these, the homeless, tempest-tossed to me, I lift my lamp beside the golden door!' - Emma Lazarus":{
|
||||
Italian:"'Datemi coloro che sono esausti, i poveri / Le folle accalcate che bramano di respirare libere, / I miseri rifiuti delle vostre coste brulicanti. / Mandatemi chi non ha casa, squassato dalle tempeste, / Sollevo la fiaccola accanto alla porta d'oro!' - Emma Lazarus"
|
||||
}
|
||||
|
||||
"+1 Production from specialists":{
|
||||
Italian:"+1 Produzione dagli Specialisti"
|
||||
German:"+1 Produktion von Spezialisten"
|
||||
@ -1566,6 +1618,10 @@
|
||||
Russian:"Сиднейский Оперный театр"
|
||||
}
|
||||
|
||||
"'Those who lose dreaming are lost.' - Australian Aboriginal saying":{
|
||||
Italian:"'Quelli che perdono i sogni sono perduti.' - Massima degli aborigeni australiani"
|
||||
}
|
||||
|
||||
/*
|
||||
"CN Tower":{
|
||||
Italian:"CN Tower" //same in Italian
|
||||
@ -1604,6 +1660,10 @@
|
||||
Russian:"Пентагон"
|
||||
}
|
||||
|
||||
"'In preparing for battle I have always found that plans are useless, but planning is indispensable.' - Dwight D. Eisenhower":{
|
||||
Italian:"'Preparandomi alla battaglia ho sempre constatato che i piani sono inutili, ma la pianificazione è indispensabile.' - Dwight D. Eisenhower"
|
||||
}
|
||||
|
||||
"Gold cost of upgrading military units reduced by 33%":{
|
||||
Spanish:"El coste de mejorar unidades con oro se reduce un 33%"
|
||||
Italian:"-33% costi in Oro per aggiornare un'unità militare"
|
||||
@ -1699,6 +1759,10 @@
|
||||
Russian:"Телескоп Хаббл"
|
||||
}
|
||||
|
||||
"'The wonder is, not that the field of stars is so vast, but that man has measured it.' - Anatole France":{
|
||||
Italian:"'La meraviglia non sta nella vastità del campo di stelle, ma nel fatto che l'uomo lo abbia misurato.' - Anatole France"
|
||||
}
|
||||
|
||||
"2 free great scientists appear":{
|
||||
Italian:"Appaiono 2 grandi scenziati gratuiti"
|
||||
German:"2 kostenlose Große Wissenschaftler erscheinen"
|
||||
|
@ -1213,7 +1213,7 @@
|
||||
}
|
||||
|
||||
"+2 Science for all specialists and Great Person tile improvements":{
|
||||
Italian:"+2 Scienza per ogni specialista e ogni miglioramento da Gran Personaggio."
|
||||
Italian:"+2 Scienza per ogni specialista e ogni miglioramento dai Grandi Personaggi."
|
||||
Simplified_Chinese:"所有专业人员和所有伟人设施+2科研"
|
||||
Russian:"+2 Наука для всех специалистов и улучшений клеток Великими людьми."
|
||||
}
|
||||
@ -1229,8 +1229,8 @@
|
||||
Italian:"Hiawatha"//Same as in Italian
|
||||
}
|
||||
|
||||
"Units move through Forest and Jungle in friendly territory as if it is a Road. These tiles can be used to establish Trade Routes upon searching The Wheel.":{
|
||||
Italian:"Le caselle di Foreste e Giungle in territorio amico agiscono come strade, e sono usate per stabilire Rotte Commerciali quando si scopre la Ruota."
|
||||
"All units move through Forest and Jungle Tiles in friendly territory as if they have roads. These tiles can be used to establish City Connections upon researching the Wheel.":{
|
||||
Italian:"Le caselle di Foreste e Giungle in territorio amico agiscono come strade, e sono usate per stabilire Rotte Commerciali quando scopri la Ruota."
|
||||
Portuguese:"Mova-se por florestas e selvas em território amigo como se fossem estradas. Estas terras podem ser usadas para estabelecer rotas de comércio após pesquisar a roda."
|
||||
French:"Les Forêt et les Jungles en territoire alliés ont les mêmes attributs que les routes. A la découverte de la Roue, elles peuvent établir des routes commerciales."
|
||||
}
|
||||
@ -1246,7 +1246,7 @@
|
||||
Italian:"Dario I"
|
||||
}
|
||||
|
||||
"Golden Ages last 50% longer. During a Golden Age, units receive +1 Movement and a +10% Combat Strenght bonus.":{
|
||||
"Golden Ages last 50% longer. During a Golden Age, units receive +1 Movement and +10% Strength":{
|
||||
Italian:"+50% durata delle Età dell'Oro, durante le quali le unità ricevono +1 Movimento e +10% Forza."
|
||||
Portuguese:"Idades douradas duram 50% mais, unidades recebem 1 movimento a mais e um bonus de +10% em força de combate."
|
||||
French:"Les Ages d'Or durent 50% plus longtemps. Durant les Ages d'Or, les unités gagnent +1 mouvement et +10% de force de Combat."
|
||||
|
@ -648,6 +648,7 @@
|
||||
}
|
||||
|
||||
"Show minimap":{
|
||||
Italian:"Mostra minimappa",
|
||||
Simplified_Chinese:"显示小地图"
|
||||
}
|
||||
|
||||
|
@ -21,8 +21,8 @@ android {
|
||||
applicationId "com.unciv.app"
|
||||
minSdkVersion 14
|
||||
targetSdkVersion 29
|
||||
versionCode 299
|
||||
versionName "3.0.6"
|
||||
versionCode 300
|
||||
versionName "3.0.7"
|
||||
}
|
||||
|
||||
// Had to add this crap for Travis to build, it wanted to sign the app
|
||||
|
@ -3,11 +3,9 @@ package com.unciv.logic.civilization
|
||||
import com.badlogic.gdx.graphics.Color
|
||||
import com.unciv.logic.city.CityInfo
|
||||
import com.unciv.logic.map.BFS
|
||||
import com.unciv.logic.map.RoadStatus
|
||||
import com.unciv.logic.map.TileInfo
|
||||
import com.unciv.models.gamebasics.GameBasics
|
||||
import com.unciv.models.gamebasics.tile.ResourceSupplyList
|
||||
import com.unciv.models.gamebasics.tr
|
||||
import java.util.*
|
||||
import kotlin.collections.HashMap
|
||||
import kotlin.collections.set
|
||||
@ -78,15 +76,20 @@ class CivInfoTransientUpdater(val civInfo: CivilizationInfo){
|
||||
citiesReachedToMediums[civInfo.getCapital()] = arrayListOf("Start")
|
||||
val allCivCities = civInfo.gameInfo.civilizations.flatMap { it.cities }
|
||||
|
||||
val theWheelIsResearched = civInfo.tech.isResearched("The Wheel")
|
||||
|
||||
val road = "Road"
|
||||
val harbor = "Harbor"
|
||||
|
||||
while(citiesToCheck.isNotEmpty() && citiesReachedToMediums.size<allCivCities.size){
|
||||
val newCitiesToCheck = mutableListOf<CityInfo>()
|
||||
for(cityToConnectFrom in citiesToCheck){
|
||||
val reachedMediums = citiesReachedToMediums[cityToConnectFrom]!!
|
||||
|
||||
// This is copypasta and can be cleaned up
|
||||
if(!reachedMediums.contains("Road")){
|
||||
if(theWheelIsResearched && !reachedMediums.contains(road)){
|
||||
|
||||
val roadBfs = BFS(cityToConnectFrom.getCenterTile()) { it.roadStatus != RoadStatus.None }
|
||||
val roadBfs = BFS(cityToConnectFrom.getCenterTile()) { it.hasRoad(civInfo) }
|
||||
roadBfs.stepToEnd()
|
||||
val reachedCities = allCivCities.filter { roadBfs.tilesReached.containsKey(it.getCenterTile())}
|
||||
for(reachedCity in reachedCities){
|
||||
@ -95,14 +98,14 @@ class CivInfoTransientUpdater(val civInfo: CivilizationInfo){
|
||||
citiesReachedToMediums[reachedCity] = arrayListOf()
|
||||
}
|
||||
val cityReachedByMediums = citiesReachedToMediums[reachedCity]!!
|
||||
if(!cityReachedByMediums.contains("Road"))
|
||||
cityReachedByMediums.add("Road")
|
||||
if(!cityReachedByMediums.contains(road))
|
||||
cityReachedByMediums.add(road)
|
||||
}
|
||||
citiesReachedToMediums[cityToConnectFrom]!!.add("Road")
|
||||
citiesReachedToMediums[cityToConnectFrom]!!.add(road)
|
||||
}
|
||||
|
||||
if(!reachedMediums.contains("Harbor")
|
||||
&& cityToConnectFrom.cityConstructions.containsBuildingOrEquivalent("Harbor")){
|
||||
if(!reachedMediums.contains(harbor)
|
||||
&& cityToConnectFrom.cityConstructions.containsBuildingOrEquivalent(harbor)){
|
||||
val seaBfs = BFS(cityToConnectFrom.getCenterTile()) { it.isWater || it.isCityCenter() }
|
||||
seaBfs.stepToEnd()
|
||||
val reachedCities = allCivCities.filter { seaBfs.tilesReached.containsKey(it.getCenterTile())}
|
||||
@ -112,10 +115,10 @@ class CivInfoTransientUpdater(val civInfo: CivilizationInfo){
|
||||
citiesReachedToMediums[reachedCity] = arrayListOf()
|
||||
}
|
||||
val cityReachedByMediums = citiesReachedToMediums[reachedCity]!!
|
||||
if(!cityReachedByMediums.contains("Harbor"))
|
||||
cityReachedByMediums.add("Harbor")
|
||||
if(!cityReachedByMediums.contains(harbor))
|
||||
cityReachedByMediums.add(harbor)
|
||||
}
|
||||
citiesReachedToMediums[cityToConnectFrom]!!.add("Harbor")
|
||||
citiesReachedToMediums[cityToConnectFrom]!!.add(harbor)
|
||||
}
|
||||
}
|
||||
citiesToCheck = newCitiesToCheck
|
||||
|
@ -94,7 +94,8 @@ class MapUnit {
|
||||
if (type.isWaterUnit() && civInfo.nation.unique == "+2 movement for all naval units")
|
||||
movement += 2
|
||||
|
||||
if(civInfo.nation.unique=="Golden Ages last 50% longer. During a Golden Age, units receive +1 Movement and +10% Strength")
|
||||
if(civInfo.goldenAges.isGoldenAge() &&
|
||||
civInfo.nation.unique=="Golden Ages last 50% longer. During a Golden Age, units receive +1 Movement and +10% Strength")
|
||||
movement+=1
|
||||
|
||||
return movement
|
||||
|
@ -324,5 +324,12 @@ open class TileInfo {
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
fun hasRoad(civInfo: CivilizationInfo): Boolean {
|
||||
if(roadStatus != RoadStatus.None) return true
|
||||
if(civInfo.nation.forestsAndJunglesAreRoads && (terrainFeature==Constants.jungle || terrainFeature==Constants.forest))
|
||||
return true
|
||||
return false
|
||||
}
|
||||
//endregion
|
||||
}
|
@ -21,7 +21,7 @@ class UnitMovementAlgorithms(val unit:MapUnit) {
|
||||
if (from.roadStatus === RoadStatus.Railroad && to.roadStatus === RoadStatus.Railroad)
|
||||
return 1 / 10f + extraCost
|
||||
|
||||
if (hasRoad(from,civInfo) && hasRoad(to,civInfo))
|
||||
if (from.hasRoad(civInfo) && to.hasRoad(civInfo))
|
||||
{
|
||||
if (unit.civInfo.tech.movementSpeedOnRoadsImproved) return 1 / 3f + extraCost
|
||||
else return 1 / 2f + extraCost
|
||||
@ -40,13 +40,6 @@ class UnitMovementAlgorithms(val unit:MapUnit) {
|
||||
return to.getLastTerrain().movementCost.toFloat() + extraCost // no road
|
||||
}
|
||||
|
||||
fun hasRoad(tileInfo:TileInfo, civInfo: CivilizationInfo): Boolean {
|
||||
if(tileInfo.roadStatus!==RoadStatus.None) return true
|
||||
if(civInfo.nation.forestsAndJunglesAreRoads && tileInfo.terrainFeature!=null
|
||||
&& (tileInfo.terrainFeature==Constants.jungle || tileInfo.terrainFeature==Constants.forest)) return true
|
||||
return false
|
||||
}
|
||||
|
||||
class ParentTileAndTotalDistance(val parentTile:TileInfo, val totalDistance: Float)
|
||||
|
||||
fun getDistanceToTilesWithinTurn(origin: Vector2, unitMovement: Float): PathsToTilesWithinTurn {
|
||||
|
Loading…
x
Reference in New Issue
Block a user