From 73816dd4703fbfbe56a7605893eb110e096eab54 Mon Sep 17 00:00:00 2001 From: Yair Morgenstern Date: Thu, 2 Jan 2020 19:37:40 +0200 Subject: [PATCH] Resolved #1598 - we now save map options for new games started --- build.gradle | 10 +++++----- core/src/com/unciv/logic/map/TileMap.kt | 1 + .../ui/newgamescreen/NewGameScreenOptionsTable.kt | 1 + 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/build.gradle b/build.gradle index f162ab3a..ec936260 100644 --- a/build.gradle +++ b/build.gradle @@ -3,11 +3,11 @@ buildscript { ext.kotlinVersion = '1.3.50' repositories { - // Chinese mirrors for quicker loading for chinese devs - maven{ url 'https://maven.aliyun.com/repository/jcenter'} - maven{ url 'https://maven.aliyun.com/repository/google'} - maven{ url 'https://maven.aliyun.com/repository/gradle-plugin'} - maven{ url 'https://maven.aliyun.com/repository/public'} + // Chinese mirrors for quicker loading for chinese devs - uncomment if you're chinese +// maven{ url 'https://maven.aliyun.com/repository/jcenter'} +// maven{ url 'https://maven.aliyun.com/repository/google'} +// maven{ url 'https://maven.aliyun.com/repository/gradle-plugin'} +// maven{ url 'https://maven.aliyun.com/repository/public'} google() mavenLocal() mavenCentral() diff --git a/core/src/com/unciv/logic/map/TileMap.kt b/core/src/com/unciv/logic/map/TileMap.kt index ba74d853..a3997e2a 100644 --- a/core/src/com/unciv/logic/map/TileMap.kt +++ b/core/src/com/unciv/logic/map/TileMap.kt @@ -25,6 +25,7 @@ class TileMap { fun clone(): TileMap { val toReturn = TileMap() toReturn.tileList.addAll(tileList.map { it.clone() }) + toReturn.mapParameters = mapParameters return toReturn } diff --git a/core/src/com/unciv/ui/newgamescreen/NewGameScreenOptionsTable.kt b/core/src/com/unciv/ui/newgamescreen/NewGameScreenOptionsTable.kt index 871bab00..b4ba8719 100644 --- a/core/src/com/unciv/ui/newgamescreen/NewGameScreenOptionsTable.kt +++ b/core/src/com/unciv/ui/newgamescreen/NewGameScreenOptionsTable.kt @@ -223,6 +223,7 @@ class NewGameScreenOptionsTable(val newGameScreen: NewGameScreen, val updatePlay fun addModCheckboxes() { val modFolders = Gdx.files.local("mods") + if(!modFolders.exists()) return val loadableMods = ArrayList() for (modFolder in modFolders.list()) {