diff --git a/build.gradle b/build.gradle index 2285fad3e3..f0040925ea 100644 --- a/build.gradle +++ b/build.gradle @@ -113,7 +113,7 @@ allprojects{ def output = 'en\n' def bundles = new File(project(':core').projectDir, 'assets/bundles/') bundles.list().sort().each{ name -> - if(name == "bundle.properties") return + if(name == "bundle.properties" || name == "global.properties") return output += name.substring("bundle".length() + 1, name.lastIndexOf('.')) + "\n" } new File(project(':core').projectDir, 'assets/locales').text = output diff --git a/core/assets/bundles/bundle.properties b/core/assets/bundles/bundle.properties index 015764dc76..9d4759a2d4 100644 --- a/core/assets/bundles/bundle.properties +++ b/core/assets/bundles/bundle.properties @@ -917,50 +917,6 @@ sector.planetaryTerminal.description = The final target.\n\nThis coastal base co sector.coastline.description = Remnants of naval unit technology have been detected at this location. Repel the enemy attacks, capture this sector, and acquire the technology. sector.navalFortress.description = The enemy has established a base on a remote, naturally-fortified island. Destroy this outpost. Acquire their advanced naval craft technology, and research it. -#do not translate -sector.facility32m.description = WIP -sector.taintedWoods.description = WIP -sector.sunkenPier.description = WIP -sector.atolls.description = WIP -sector.frontier.description = WIP -sector.infestedCanyons.description = WIP -sector.polarAerodrome.description = WIP -sector.testingGrounds.description = WIP -sector.perilousHarbor.description = WIP -sector.weatheredChannels.description = WIP -sector.fallenVessel.description = WIP -sector.mycelialBastion.description = WIP -sector.cruxscape.description = WIP -sector.geothermalStronghold.description = WIP - -#names, do not translate -sector.frozenForest.credit = Elixias Adrys -sector.facility32m.credit = Stormride_R -sector.taintedWoods.credit = Stormride_R -sector.sunkenPier.credit = Stormride_R -sector.atolls.credit = Stormride_R -sector.frontier.credit = Stormride_R -sector.infestedCanyons.credit = Skeledragon -sector.polarAerodrome.credit = hhh i 17 -sector.testingGrounds.credit = Stormride_R -sector.perilousHarbor.credit = inkognito626 -sector.weatheredChannels.credit = Skeledragon -sector.fallenVessel.credit = wpx, Stormride_R, Nahan -sector.mycelialBastion.credit = Skeledragon -sector.planetaryTerminal.credit = Skeledragon -sector.cruxscape.credit = Stormride_R -sector.geothermalStronghold.credit = Skeledragon -sector.overgrowth.credit = Skeledragon -sector.stainedMountains.credit = Pitchblende -sector.ruinousShores.credit = Pitchblende -sector.nuclearComplex.credit = Pitchblende -sector.coastline.credit = Stormride_R -sector.tarFields.credit = Dexapnow -sector.saltFlats.credit = Dexapnow -sector.windsweptIslands.credit = Stormride_R, Anuke -sector.navalFortress.credit = blackberry2093 -sector.desolateRift.credit = hhh i 17 - sector.onset.name = The Onset sector.aegis.name = Aegis sector.lake.name = Lake diff --git a/core/assets/bundles/global.properties b/core/assets/bundles/global.properties new file mode 100644 index 0000000000..deedd40271 --- /dev/null +++ b/core/assets/bundles/global.properties @@ -0,0 +1,45 @@ +# This file contains special global strings that don't need to be translated. +# The contents of this bundle are merged into Core.bundle, and otherwise act as normal translated strings. + +sector.frozenForest.credit = Elixias Adrys +sector.facility32m.credit = Stormride_R +sector.taintedWoods.credit = Stormride_R +sector.sunkenPier.credit = Stormride_R +sector.atolls.credit = Stormride_R +sector.frontier.credit = Stormride_R +sector.infestedCanyons.credit = Skeledragon +sector.polarAerodrome.credit = hhh i 17 +sector.testingGrounds.credit = Stormride_R +sector.perilousHarbor.credit = inkognito626 +sector.weatheredChannels.credit = Skeledragon +sector.fallenVessel.credit = wpx, Stormride_R, Nahan +sector.mycelialBastion.credit = Skeledragon +sector.planetaryTerminal.credit = Skeledragon +sector.cruxscape.credit = Stormride_R +sector.geothermalStronghold.credit = Skeledragon +sector.overgrowth.credit = Skeledragon +sector.stainedMountains.credit = Pitchblende +sector.ruinousShores.credit = Pitchblende +sector.nuclearComplex.credit = Pitchblende +sector.coastline.credit = Stormride_R +sector.tarFields.credit = Dexapnow +sector.saltFlats.credit = Dexapnow +sector.windsweptIslands.credit = Stormride_R, Anuke +sector.navalFortress.credit = blackberry2093 +sector.desolateRift.credit = hhh i 17 + +#TODO: remove, create a proper description, move into bundle.properties +sector.facility32m.description = WIP +sector.taintedWoods.description = WIP +sector.sunkenPier.description = WIP +sector.atolls.description = WIP +sector.frontier.description = WIP +sector.infestedCanyons.description = WIP +sector.polarAerodrome.description = WIP +sector.testingGrounds.description = WIP +sector.perilousHarbor.description = WIP +sector.weatheredChannels.description = WIP +sector.fallenVessel.description = WIP +sector.mycelialBastion.description = WIP +sector.cruxscape.description = WIP +sector.geothermalStronghold.description = WIP \ No newline at end of file diff --git a/core/src/mindustry/Vars.java b/core/src/mindustry/Vars.java index 61f108e074..4d2b9274a8 100644 --- a/core/src/mindustry/Vars.java +++ b/core/src/mindustry/Vars.java @@ -9,6 +9,7 @@ import arc.scene.ui.layout.*; import arc.struct.*; import arc.util.*; import arc.util.Log.*; +import arc.util.io.*; import mindustry.ai.*; import mindustry.async.*; import mindustry.core.*; @@ -536,5 +537,9 @@ public class Vars implements Loadable{ } } } + + StringMap globalBundle = new StringMap(); + PropertiesUtils.load(globalBundle, files.internal("bundles/global.properties").reader(512, "UTF-8")); + bundle.getProperties().putAll(globalBundle); } }