diff --git a/core/src/com/unciv/models/metadata/GameParameters.kt b/core/src/com/unciv/models/metadata/GameParameters.kt index 4a8959130c..f990745b8f 100644 --- a/core/src/com/unciv/models/metadata/GameParameters.kt +++ b/core/src/com/unciv/models/metadata/GameParameters.kt @@ -25,7 +25,7 @@ class GameParameters { // Default values are the default new game // By default, all victory types except Diplomacy as it is quite new var victoryTypes: ArrayList = arrayListOf(VictoryType.Cultural, VictoryType.Domination, VictoryType.Scientific) - var startingEra = "Ancient Era" + var startingEra = "Ancient era" var isOnlineMultiplayer = false var baseRuleset: BaseRuleset = BaseRuleset.Civ_V_Vanilla diff --git a/core/src/com/unciv/ui/worldscreen/WorldScreenTopBar.kt b/core/src/com/unciv/ui/worldscreen/WorldScreenTopBar.kt index 4f9294a88e..19534df5a8 100644 --- a/core/src/com/unciv/ui/worldscreen/WorldScreenTopBar.kt +++ b/core/src/com/unciv/ui/worldscreen/WorldScreenTopBar.kt @@ -294,8 +294,7 @@ class WorldScreenTopBar(val worldScreen: WorldScreen) : Table() { private fun getEquivalentTurn(gameInfo: GameInfo): Int { val totalTurns = 500f * gameInfo.gameParameters.gameSpeed.modifier - val startPercent = gameInfo.ruleSet.eras[gameInfo.gameParameters.startingEra]?.startPercent - if (startPercent == null) return gameInfo.turns + val startPercent = gameInfo.ruleSet.eras[gameInfo.gameParameters.startingEra]!!.startPercent return gameInfo.turns + ((totalTurns * startPercent).toInt() / 100) } } diff --git a/tests/src/com/unciv/testing/SerializationTests.kt b/tests/src/com/unciv/testing/SerializationTests.kt index b510ba4729..fd83d2cf1d 100644 --- a/tests/src/com/unciv/testing/SerializationTests.kt +++ b/tests/src/com/unciv/testing/SerializationTests.kt @@ -51,7 +51,6 @@ class SerializationTests { players.add(Player("Rome").apply { playerType = PlayerType.Human }) players.add(Player("Greece")) religionEnabled = true - startingEra = "Ancient era" } val mapParameters = MapParameters().apply { mapSize = MapSizeNew(MapSize.Tiny)