Merge remote-tracking branch 'origin/master'

This commit is contained in:
Anuken 2024-06-08 12:55:11 -04:00
commit d8e5818a45
7 changed files with 889 additions and 857 deletions

View file

@ -57,7 +57,7 @@ mods.browser.sortstars = Mejor valorados
schematic = Esquema
schematic.add = Guardar esquema...
schematics = Esquemas
schematic.search = Search schematics...
schematic.search = Buscar esquemas..
schematic.replace = Ya existe un esquema con ese nombre. ¿Quieres reemplazarlo?
schematic.exists = Ya existe un esquema con ese nombre.
schematic.import = Importar esquema...
@ -70,7 +70,7 @@ schematic.shareworkshop = Compartir en Steam Workshop
schematic.flip = [accent][[{0}][]/[accent][[{1}][]: Invertir esquema
schematic.saved = Esquema guardado.
schematic.delete.confirm = Este esquema será absolutamente erradicado.
schematic.edit = Edit Schematic
schematic.edit = Editar esquema
schematic.info = {0}x{1}, {2} bloques
schematic.disabled = [scarlet]Esquemas desactivados.[]\nNo está permitido usar esquemas en este [accent]mapa[] o [accent]servidor.
schematic.tags = Etiquetas:
@ -1002,7 +1002,7 @@ stat.immunities = Inmune a
stat.healing = Curación
ability.forcefield = Área de Escudo
ability.forcefield.description = Projects a force shield that absorbs bullets
ability.forcefield.description = Projecta un campo de fuerza que absorve balas
ability.repairfield = Área de Reparación
ability.repairfield.description = Repairs nearby units
ability.statusfield = Área de Potenciación
@ -1022,8 +1022,8 @@ ability.suppressionfield.description = Stops nearby repair buildings
ability.energyfield = Campo de Energía
ability.energyfield.description = Zaps nearby enemies
ability.energyfield.healdescription = Zaps nearby enemies and heals allies
ability.regen = Regeneration
ability.regen.description = Regenerates own health over time
ability.regen = Regeneración
ability.regen.description = Regenera su propia salud con el tiempo
ability.liquidregen = Liquid Absorption
ability.liquidregen.description = Absorbs liquid to heal itself
ability.spawndeath = Death Spawns
@ -1311,7 +1311,7 @@ mode.pvp.description = Combate contra otros jugadores localmente.\n[gray]Requier
mode.attack.name = Ataque
mode.attack.description = Destruye la base enemiga. \n[gray]Requiere un núcleo rojo en el mapa.
mode.custom = Normas personalizadas
rules.invaliddata = Invalid clipboard data.
rules.invaliddata = Datos del portapeles invalidos.
rules.hidebannedblocks = Ocultar bloques prohibidos
rules.infiniteresources = Recursos infinitos
@ -1355,7 +1355,7 @@ rules.buildcostmultiplier = Multiplicador de coste de construcción
rules.buildspeedmultiplier = Multiplicador de velocidad de construcción
rules.deconstructrefundmultiplier = Multiplicador de devolución de desconstrucción
rules.waitForWaveToEnd = Las oleadas esperan a los enemigos
rules.wavelimit = Map Ends After Wave
rules.wavelimit = El mapa termina despues de la oleada
rules.dropzoneradius = Radio de zona de aterrizaje:[lightgray] (bloques)
rules.unitammo = Las unidades necesitan munición
rules.enemyteam = Equipo enemigo
@ -1379,7 +1379,7 @@ rules.weather.frequency = Frecuencia:
rules.weather.always = Siempre
rules.weather.duration = Duracion:
rules.placerangecheck.info = Prevents players from placing anything near enemy buildings. When trying to place a turret, the range is increased, so the turret will not be able to reach the enemy.
rules.onlydepositcore.info = Prevents units from depositing items into any buildings except cores.
rules.onlydepositcore.info = Evita que las unidades depositen materiales en calquiera estructura a excepción del nucleo.
content.item.name = Objetos
content.liquid.name = Líquidos

View file

@ -854,13 +854,13 @@ sector.split.description = 이 지역에 최소한으로 존재하는 적 주둔
sector.basin.description = {임시}\n\n현재의 마지막 지역. 이 지역은 도전 레벨입니다 - 이후 릴리즈에서 많은 지역이 더 추가될 예정입니다.
sector.marsh.description = 이 지역은 아르키사이트가 풍부하지만 분출구의 수는 한정적입니다.\n[accent]화학적 연소실[]을 건설하여 전력을 생산하시오.
sector.peaks.description = 이 지역의 산악 지형은 대부분의 기체를 무용지물로 만들었습니다. 비행 가능한 기체가 필요합니다.\n적의 방공망에 유의하십시오. 일부 시설은 지원 건물을 공격하여 무력화시킬 수 있습니다.
sector.ravine.description = 적의 중요한 이동 경로이긴 하지만, 해당 구역에선 적의 코어가 감지되지 않았습니다. 다양한 적군을 맞닥뜨릴 것으로 예상됩니다.\n[accent]금[]을 생산하십시오. 포탑 [accent]어플릭트[]를 건설하십시오.
sector.ravine.description = 적의 중요한 이동 경로이긴 하지만, 해당 구역에선 적의 코어가 감지되지 않았습니다. 다양한 적군을 맞닥뜨릴 것으로 예상됩니다.\n[accent]서지 합금[]을 생산하십시오. 포탑 [accent]어플릭트[]를 건설하십시오.
sector.caldera-erekir.description = 이 지역에서 탐지된 자원은 여러 섬에 분산되어 있습니다 .\n드론을 기반으로 한 운송수단을 연구하고 활용하시오.
sector.stronghold.description = 이 지역의 대규모 적 야영지에는 적들이 지키고 있는 상당한 양의 [accent]토륨[] 매장지가 있습니다.\n더 높은 등급의 기체와 포탑을 연구할 때 사용합니다.
sector.crevice.description = 적들은 이 지역에서 당신의 기지를 제거하기 위해 맹렬한 공격부대를 보낼 것입니다.\n[accent]탄화물[]과 [accent]열분해 발전기[]를 연구하는 것은 살아남기 위해 반드시 필요합니다.
sector.siege.description = 이 지역은 두 갈래의 공격을 강요하는 두 개의 평행 협곡이 특징입니다.\n더 강력한 전차 기체를 만들기 위한 능력을 얻기 위해 [accent]시아노겐[]을 연구하시오.\n주의: 적의 장거리 발사체가 감지되었습니다. 미사일은 충돌 전에 격추될 수 있습니다.
sector.crossroads.description = 이 지역의 적 기지는 다양한 지형에 설치되어 있습니다. 적응하기 위해 다양한 기체를 연구하시오.\n또한, 일부 기지는 보호막으로 보호되고 있습니다. 그들이 어떻게 전력을 공급받는지 알아보시오.
sector.karst.description = 이 지역은 자원이 풍부하지만, 새로운 코어가 착륙하면 적에게 공격을 받을 것입니다.\n자원의 이점을 활용하고 [accent]메타[]를 연구하시오.
sector.karst.description = 이 지역은 자원이 풍부하지만, 새로운 코어가 착륙하면 적에게 공격을 받을 것입니다.\n자원의 이점을 활용하고 [accent]위상 섬유[]를 연구하시오.
sector.origin.description = 상당한 적이 존재하는 마지막 지역입니다.\n가능한 연구 기회가 남아 있지 않습니다. 오직 모든 적의 코어를 파괴하는 데만 집중하십시오.
status.burning.name = 발화
@ -1390,8 +1390,8 @@ item.titanium.name = 티타늄
item.thorium.name = 토륨
item.silicon.name = 실리콘
item.plastanium.name = 플라스터늄
item.phase-fabric.name = 메타
item.surge-alloy.name =
item.phase-fabric.name = 위상 섬유
item.surge-alloy.name = 서지 합
item.spore-pod.name = 포자 꼬투리
item.sand.name = 모래
item.blast-compound.name = 폭발물
@ -1568,8 +1568,8 @@ block.titanium-wall.name = 티타늄 벽
block.titanium-wall-large.name = 대형 티타늄 벽
block.plastanium-wall.name = 플라스터늄 벽
block.plastanium-wall-large.name = 대형 플라스터늄 벽
block.phase-wall.name = 메타
block.phase-wall-large.name = 대형 메타
block.phase-wall.name = 위상
block.phase-wall-large.name = 대형 위상
block.thorium-wall.name = 토륨 벽
block.thorium-wall-large.name = 대형 토륨 벽
block.door.name =
@ -1596,7 +1596,7 @@ block.illuminator.name = 조명
block.overflow-gate.name = 포화 필터
block.underflow-gate.name = 불포화 필터
block.silicon-smelter.name = 실리콘 제련소
block.phase-weaver.name = 메타 제조
block.phase-weaver.name = 위상 방직
block.pulverizer.name = 분쇄기
block.cryofluid-mixer.name = 냉각수 혼합기
block.melter.name = 융해기
@ -1606,7 +1606,7 @@ block.separator.name = 광재 분리기
block.coal-centrifuge.name = 석탄 정제기
block.power-node.name = 전력 노드
block.power-node-large.name = 대형 전력 노드
block.surge-tower.name = 설금 타워
block.surge-tower.name = 서지 타워
block.diode.name = 다이오드
block.battery.name = 배터리
block.battery-large.name = 대형 배터리
@ -1634,7 +1634,7 @@ block.tsunami.name = 쓰나미
block.swarmer.name = 스웜
block.salvo.name = 살보
block.ripple.name = 립플
block.phase-conveyor.name = 메타 컨베이어
block.phase-conveyor.name = 위상 컨베이어
block.bridge-conveyor.name = 다리 컨베이어
block.plastanium-compressor.name = 플라스터늄 압축기
block.pyratite-mixer.name = 파이라타이트 혼합기
@ -1646,7 +1646,7 @@ block.repair-point.name = 수리 지점
block.repair-turret.name = 수리 포탑
block.pulse-conduit.name = 펄스 파이프
block.plated-conduit.name = 도금된 파이프
block.phase-conduit.name = 메타 파이프
block.phase-conduit.name = 위상 파이프
block.liquid-router.name = 액체 분배기
block.liquid-tank.name = 액체 탱크
block.liquid-container.name = 액체 컨테이너
@ -1658,11 +1658,11 @@ block.mass-driver.name = 매스 드라이버
block.blast-drill.name = 압축 공기분사 드릴
block.impulse-pump.name = 충격 펌프
block.thermal-generator.name = 지열 발전기
block.surge-smelter.name = 설금 제련소
block.surge-smelter.name = 서지 제련소
block.mender.name = 멘더
block.mend-projector.name = 수리 프로젝터
block.surge-wall.name = 설금
block.surge-wall-large.name = 설금
block.surge-wall.name = 서지
block.surge-wall-large.name = 서지
block.cyclone.name = 사이클론
block.fuse.name = 퓨즈
block.shock-mine.name = 전격 지뢰
@ -1679,10 +1679,10 @@ block.segment.name = 세그먼트
block.ground-factory.name = 지상 공장
block.air-factory.name = 항공 공장
block.naval-factory.name = 해양 공장
block.additive-reconstructor.name = 재구성기 : Additive
block.multiplicative-reconstructor.name = 재구성기 : Multiplicative
block.exponential-reconstructor.name = 재구성기 : Exponential
block.tetrative-reconstructor.name = 재구성기 : Tetrative
block.additive-reconstructor.name = 덧셈식 재구성기
block.multiplicative-reconstructor.name = 곱셈식 재구성기
block.exponential-reconstructor.name = 거듭제곱식 재구성기
block.tetrative-reconstructor.name = 테트레이션식 재구성기
block.payload-conveyor.name = 화물 컨베이어
block.payload-router.name = 화물 분배기
block.duct.name = 도관
@ -1767,15 +1767,15 @@ block.atmospheric-concentrator.name = 대기 농축기
block.oxidation-chamber.name = 산화실
block.electric-heater.name = 전기 가열기
block.slag-heater.name = 광재 가열기
block.phase-heater.name = 메타 가열기
block.phase-heater.name = 위상 가열기
block.heat-redirector.name = 열 전송기
block.heat-router.name = 열 분배기
block.slag-incinerator.name = 광재 소각로
block.carbide-crucible.name = 탄화물 도가니
block.slag-centrifuge.name = 광재 원심분리기
block.surge-crucible.name = 설금 도가니
block.surge-crucible.name = 서지 도가니
block.cyanogen-synthesizer.name = 시아노겐 합성기
block.phase-synthesizer.name = 메타 합성기
block.phase-synthesizer.name = 위상 합성기
block.heat-reactor.name = 열 반응로
block.beryllium-wall.name = 베릴륨 벽
block.beryllium-wall-large.name = 대형 베릴륨 벽
@ -1784,8 +1784,8 @@ block.tungsten-wall-large.name = 대형 텅스텐 벽
block.blast-door.name = 방폭문
block.carbide-wall.name = 탄화물 벽
block.carbide-wall-large.name = 대형 탄화물 벽
block.reinforced-surge-wall.name = 보강된 설금
block.reinforced-surge-wall-large.name = 보강된 대형 설금
block.reinforced-surge-wall.name = 보강된 서지
block.reinforced-surge-wall-large.name = 보강된 대형 서지
block.shielded-wall.name = 보호된 벽
block.radar.name = 레이더
block.build-tower.name = 건설 타워
@ -1797,8 +1797,8 @@ block.armored-duct.name = 장갑 도관
block.overflow-duct.name = 포화 도관
block.underflow-duct.name = 불포화 도관
block.duct-unloader.name = 언로더 도관
block.surge-conveyor.name = 설금 컨베이어
block.surge-router.name = 설금 분배기
block.surge-conveyor.name = 서지 컨베이어
block.surge-router.name = 서지 분배기
block.unit-cargo-loader.name = 기체 화물 적재소
block.unit-cargo-unload-point.name = 기체 화물 하역지점
block.reinforced-pump.name = 보강된 펌프
@ -2011,8 +2011,8 @@ block.multi-press.description = 석탄을 흑연으로 압축합니다. 냉각
block.silicon-smelter.description = 석탄과 모래에서 실리콘을 정제합니다.
block.kiln.description = 모래와 납을 강화 유리로 제련합니다.
block.plastanium-compressor.description = 석유와 티타늄으로 플라스터늄을 생산합니다.
block.phase-weaver.description = 토륨과 모래로 메타를 합성합니다.
block.surge-smelter.description = 티타늄, 납, 실리콘 및 구리를 금으로 혼합합니다.
block.phase-weaver.description = 토륨과 모래로 위상 섬유를 합성합니다.
block.surge-smelter.description = 티타늄, 납, 실리콘 및 구리를 서지 합금으로 혼합합니다.
block.cryofluid-mixer.description = 물과 미세 티타늄 분말을 냉각수로 혼합합니다.
block.blast-mixer.description = 파이라타이트와 포자로 폭발물을 생산합니다.
block.pyratite-mixer.description = 석탄, 납, 그리고 모래를 파이라타이트로 혼합합니다.
@ -2045,9 +2045,9 @@ block.surge-wall-large.description = 적 발사체로부터 아군 구조물을
block.door.description = 탭하여 열거나 닫을 수 있는 벽입니다.
block.door-large.description = 탭하여 열거나 닫을 수 있는 벽입니다.\n여러 타일을 차지합니다.
block.mender.description = 주변 블록을 주기적으로 수리합니다.\n선택적으로 실리콘을 사용하여 범위와 효율성을 향상할 수 있습니다.
block.mend-projector.description = 주변의 블록을 수리합니다.\n선택적으로 메타를 사용하여 범위와 효율성을 향상할 수 있습니다.
block.overdrive-projector.description = 주변 건물의 속도를 높입니다.\n선택적으로 메타를 사용하여 범위와 효율성을 향상할 수 있습니다.
block.force-projector.description = 주위에 육각형 역장을 형성하여 내부의 건물과 기체를 공격으로부터 보호합니다. 지속해서 많은 피해를 받을 경우 과열됩니다.\n선택적으로 냉각수를 사용해서 과열 방지를, 메타를 사용해서 보호막 크기를 증가시킬 수 있습니다.
block.mend-projector.description = 주변의 블록을 수리합니다.\n선택적으로 위상 섬유를 사용하여 범위와 효율성을 향상할 수 있습니다.
block.overdrive-projector.description = 주변 건물의 속도를 높입니다.\n선택적으로 위상 섬유를 사용하여 범위와 효율성을 향상할 수 있습니다.
block.force-projector.description = 주위에 육각형 역장을 형성하여 내부의 건물과 기체를 공격으로부터 보호합니다. 지속해서 많은 피해를 받을 경우 과열됩니다.\n선택적으로 냉각수를 사용해서 과열 방지를, 위상 섬유를 사용해서 보호막 크기를 증가시킬 수 있습니다.
block.shock-mine.description = 접촉한 적 기체에게 전격 아크를 방출합니다.
block.conveyor.description = 자원을 앞으로 운반합니다. 회전하여 방향을 바꿀 수 있습니다.
block.titanium-conveyor.description = 자원을 앞으로 운반합니다. 컨베이어보다 더 빠릅니다.
@ -2130,7 +2130,7 @@ block.parallax.description = 공중 목표물을 끌어오는 견인 광선을
block.tsunami.description = 적을 향해 강력한 액체 줄기를 발사합니다. 물이 공급되면 자동으로 화재를 진압합니다.
block.silicon-crucible.description = 파이라타이트를 추가 열원으로 사용하여 모래와 석탄에서 실리콘을 정제합니다. 뜨거운 곳에서 더 효율적입니다.
block.disassembler.description = 광재를 낮은 효율로 미량의 희귀한 광물들로 분리합니다. 토륨을 생산할 수 있습니다.
block.overdrive-dome.description = 주변 건물의 속도를 높입니다. 작동하려면 메타와 실리콘이 필요합니다.
block.overdrive-dome.description = 주변 건물의 속도를 높입니다. 작동하려면 위상 섬유와 실리콘이 필요합니다.
block.payload-conveyor.description = 공장에서 생산된 기체같은 큰 화물을 운반합니다.
block.payload-router.description = 화물을 3가지 방향으로 번갈아 운반합니다.
block.ground-factory.description = 지상 기체를 생산합니다. 생산된 기체는 바로 사용하거나 강화를 위해 재구성기로 이동할 수 있습니다.
@ -2167,13 +2167,13 @@ block.silicon-arc-furnace.description = 모래와 흑연에서 실리콘을 정
block.oxidation-chamber.description = 베릴륨과 오존을 산화물로 전환합니다. 부산물로 열을 방출합니다.
block.electric-heater.description = 블록에 열을 가합니다. 많은 양의 전력이 필요합니다.
block.slag-heater.description = 블록에 열을 가합니다. 광재가 필요합니다.
block.phase-heater.description = 블록에 열을 가합니다. 메타가 필요합니다.
block.phase-heater.description = 블록에 열을 가합니다. 위상 섬유가 필요합니다.
block.heat-redirector.description = 누적된 열을 다른 블록으로 전달합니다.
block.heat-router.description = 축적된 열을 세 가지 출력 방향으로 분산시킵니다.
block.electrolyzer.description = 물을 수소와 오존 가스로 변환합니다.
block.atmospheric-concentrator.description = 대기에서 질소를 농축합니다. 열이 필요합니다.
block.surge-crucible.description = 광재와 실리콘으로 금을 형성합니다. 열이 필요합니다.
block.phase-synthesizer.description = 토륨, 모래 및 오존으로부터 메타를 합성합니다. 열이 필요합니다.
block.surge-crucible.description = 광재와 실리콘으로 서지 합금을 형성합니다. 열이 필요합니다.
block.phase-synthesizer.description = 토륨, 모래 및 오존으로부터 위상 섬유를 합성합니다. 열이 필요합니다.
block.carbide-crucible.description = 흑연과 텅스텐을 탄화물로 융합합니다. 열이 필요합니다.
block.cyanogen-synthesizer.description = 아르키사이트와 흑연으로부터 시아노겐을 합성합니다. 열이 필요합니다.
block.slag-incinerator.description = 비휘발성 자원 또는 액체를 소각합니다. 광재가 필요합니다.
@ -2208,7 +2208,7 @@ block.duct-unloader.description = 선택한 자원을 뒤의 블록에서 빼냅
block.underflow-duct.description = 포화 도관의 반대입니다. 왼쪽 및 오른쪽 경로가 차단된 경우 앞쪽으로 출력합니다.
block.reinforced-liquid-junction.description = 두 개의 교차 파이프 사이의 다리 역할을 합니다.
block.surge-conveyor.description = 자원을 일괄적으로 이동합니다. 전력을 공급하여 가속할 수 있습니다. 인접한 블록에 전원을 공급합니다.
block.surge-router.description = 설금 컨베이어에서 항목을 세 방향으로 균등하게 분배합니다. 전력을 공급하여 가속할 수 있습니다. 인접한 블록에 전원을 공급합니다.
block.surge-router.description = 서지 컨베이어에서 항목을 세 방향으로 균등하게 분배합니다. 전력을 공급하여 가속할 수 있습니다. 인접한 블록에 전원을 공급합니다.
block.unit-cargo-loader.description = 화물용 드론을 제작합니다. 드론은 자동으로 자원과 일치하는 필터로 설정된 기체 화물 하역지점으로 분배합니다.
block.unit-cargo-unload-point.description = 화물 드론의 하역지점 역할을 합니다. 선택한 필터와 일치하는 자원을 받아들입니다.
block.beam-node.description = 전력을 다른 블록에 직선 방향으로 전송합니다. 소량의 전력을 저장합니다.
@ -2217,7 +2217,7 @@ block.turbine-condenser.description = 분출구에 배치할 때 전력을 발
block.chemical-combustion-chamber.description = 아르키사이트와 오존으로 전력을 생산합니다.
block.pyrolysis-generator.description = 아르키사이트와 광재로 많은 양의 전력을 생산합니다. 부산물로 물이 발생합니다.
block.flux-reactor.description = 가열 시 많은 양의 전력을 발생시킵니다. 안정제로 시아노겐이 필요합니다. 전력 출력 및 시아노겐 요구량은 열 입력에 비례합니다.\n시아노겐이 부족할 경우 폭발합니다.
block.neoplasia-reactor.description = 아르키사이트, 물 및 메타를 사용하여 많은 양의 전력을 생산합니다. 부산물로 열과 위험한 신생물이 발생합니다.\n도관을 통해 반응로에서 신생물이 제거되지 않으면 격렬하게 폭발합니다.
block.neoplasia-reactor.description = 아르키사이트, 물 및 위상 섬유를 사용하여 많은 양의 전력을 생산합니다. 부산물로 열과 위험한 신생물이 발생합니다.\n도관을 통해 반응로에서 신생물이 제거되지 않으면 격렬하게 폭발합니다.
block.build-tower.description = 범위 내의 구조물을 자동으로 재구축하고 다른 유닛의 건설을 지원합니다.
block.regen-projector.description = 정사각형 둘레의 범위 안에 있는 아군 구조물을 천천히 수리합니다. 수소가 필요합니다.
block.reinforced-container.description = 소량의 자원을 저장합니다. 내용물은 언로더를 통해 빼낼 수 있습니다. 코어의 저장 용량은 늘리지 않습니다.

File diff suppressed because it is too large Load diff

View file

@ -159,7 +159,7 @@ xStaBUx
WayZer
SITUVNgcd
Gabriel "red" Fondato
Yoru Kitsune
CoCo Snow
summoner
OpalSoPL
BalaM314

View file

@ -143,49 +143,7 @@ public interface Platform{
*/
default void showFileChooser(boolean open, String title, String extension, Cons<Fi> cons){
if(OS.isWindows || OS.isMac){
String formatted = (title.startsWith("@") ? Core.bundle.get(title.substring(1)) : title).replaceAll("\"", "'");
//native file dialog
Threads.daemon(() -> {
try{
FileDialogs.loadNatives();
String result;
//on MacOS, .msav is not properly recognized until I put garbage into the array?
String[] extensions = OS.isMac && open ? new String[]{"", "*." + extension} : new String[]{"*." + extension};
if(open){
result = FileDialogs.openFileDialog(formatted, FileChooser.getLastDirectory().absolutePath(), extensions, "." + extension + " files", false);
}else{
result = FileDialogs.saveFileDialog(formatted, FileChooser.getLastDirectory().child("file." + extension).absolutePath(), extensions, "." + extension + " files");
}
if(result == null) return;
if(result.length() > 1 && result.contains("\n")){
result = result.split("\n")[0];
}
//cancelled selection, ignore result
if(result.isEmpty() || result.equals("\n")) return;
if(result.endsWith("\n")) result = result.substring(0, result.length() - 1);
if(result.contains("\n")) throw new IOException("invalid input: \"" + result + "\"");
Fi file = Core.files.absolute(result);
Core.app.post(() -> {
FileChooser.setLastDirectory(file.isDirectory() ? file : file.parent());
if(!open){
cons.get(file.parent().child(file.nameWithoutExtension() + "." + extension));
}else{
cons.get(file);
}
});
}catch(Throwable error){
Log.err("Failure to execute native file chooser", error);
Core.app.post(() -> defaultFileDialog(open, title, extension, cons));
}
});
showNativeFileChooser(open, title, cons, extension);
}else if(OS.isLinux && !OS.isAndroid){
showZenity(open, title, new String[]{extension}, cons, () -> defaultFileDialog(open, title, extension, cons));
}else{
@ -268,6 +226,8 @@ public interface Platform{
default void showMultiFileChooser(Cons<Fi> cons, String... extensions){
if(mobile){
showFileChooser(true, extensions[0], cons);
}else if(OS.isWindows || OS.isMac){
showNativeFileChooser(true, "@open", cons, extensions);
}else if(OS.isLinux && !OS.isAndroid){
showZenity(true, "@open", extensions, cons, () -> defaultMultiFileChooser(cons, extensions));
}else{
@ -279,6 +239,68 @@ public interface Platform{
new FileChooser("@open", file -> Structs.contains(extensions, file.extension().toLowerCase()), true, cons).show();
}
default void showNativeFileChooser(boolean open, String title, Cons<Fi> cons, String... shownExtensions){
String formatted = (title.startsWith("@") ? Core.bundle.get(title.substring(1)) : title).replaceAll("\"", "'");
//this should never happen unless someone is being dumb with the parameters
String[] ext = shownExtensions == null || shownExtensions.length == 0 ? new String[]{""} : shownExtensions;
//native file dialog
Threads.daemon(() -> {
try{
FileDialogs.loadNatives();
String result;
String[] patterns = new String[ext.length];
for(int i = 0; i < ext.length; i++){
patterns[i] = "*." + ext[i];
}
//on MacOS, .msav is not properly recognized until I put garbage into the array?
if(patterns.length == 1 && OS.isMac && open){
patterns = new String[]{"", "*." + ext[0]};
}
if(open){
result = FileDialogs.openFileDialog(formatted, FileChooser.getLastDirectory().absolutePath(), patterns, "." + ext[0] + " files", false);
}else{
result = FileDialogs.saveFileDialog(formatted, FileChooser.getLastDirectory().child("file." + ext[0]).absolutePath(), patterns, "." + ext[0] + " files");
}
if(result == null) return;
if(result.length() > 1 && result.contains("\n")){
result = result.split("\n")[0];
}
//cancelled selection, ignore result
if(result.isEmpty() || result.equals("\n")) return;
if(result.endsWith("\n")) result = result.substring(0, result.length() - 1);
if(result.contains("\n")) throw new IOException("invalid input: \"" + result + "\"");
Fi file = Core.files.absolute(result);
Core.app.post(() -> {
FileChooser.setLastDirectory(file.isDirectory() ? file : file.parent());
if(!open){
cons.get(file.parent().child(file.nameWithoutExtension() + "." + ext[0]));
}else{
cons.get(file);
}
});
}catch(Throwable error){
Log.err("Failure to execute native file chooser", error);
Core.app.post(() -> {
if(ext.length > 1){
defaultMultiFileChooser(cons, ext);
}else{
defaultFileDialog(open, title, ext[0], cons);
}
});
}
});
}
/** Hide the app. Android only. */
default void hide(){
}

View file

@ -146,6 +146,11 @@ public class ContentParser{
readFields(result, data);
return result;
});
put(MassDriverBolt.class, (type, data) -> {
MassDriverBolt result = (MassDriverBolt)make(MassDriverBolt.class);
readFields(result, data);
return result;
});
put(AmmoType.class, (type, data) -> {
//string -> item
//if liquid ammo support is added, this should scan for liquids as well

View file

@ -266,7 +266,7 @@
},
{
"name": "XuwenHost",
"address": ["mdt.xuwenblock.cn:6568","mdt.xuwenblock.cn:6567","106.14.14.210"]
"address": ["mdt.xuwenblock.cn:6567","rack1.rainplay.cn:59196"]
},
{
"name": "Atomic",
@ -311,5 +311,9 @@
{
"name": "ArmyOFUkraine",
"address": ["194.247.42.131:27715"]
},
{
"name": "Natrition",
"address": ["94.103.90.138"]
}
]