Импорт пресета песочницы .cfg и списка модов
Сборки нередко раздают только пресет одиночной игры. Внутри это плоский список «Параметр=значение» с точками вместо вложенности, поэтому значения переносятся в SandboxVars.lua профиля по одному: комментарии игры и порядок остаются на месте, а параметры модов, которых в файле ещё нет, пропускаются со счётом. Если файла нет вовсе, он собирается из пресета целиком. Заодно панель принимает строку из игровой кнопки «Поделиться» («Название:ModA;ModB;…»): она заменяет список включённых модов, сохраняя порядок загрузки. Идентификаторов мастерской в такой строке нет, поэтому пакеты добавляются только для модов, чьи файлы уже на диске, а про остальные панель предупреждает. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
+24
-2
@@ -300,7 +300,7 @@ const STRINGS = {
|
||||
"profiles.create": "Создать профиль",
|
||||
|
||||
"import.title": "Импорт пресета сборки",
|
||||
"import.fileHint": "ZIP-пакет сборки: панель возьмёт из него серверный .ini, настройки песочницы и точки появления, остальное пропустит.",
|
||||
"import.fileHint": "ZIP-пакет сборки или пресет песочницы .cfg. Из архива панель возьмёт серверный .ini, настройки песочницы и точки появления, остальное пропустит.",
|
||||
"import.reading": "Читаю архив…",
|
||||
"import.set": "Набор из архива",
|
||||
"import.server": "Сервер: {name}",
|
||||
@@ -325,6 +325,17 @@ const STRINGS = {
|
||||
"import.confirm": "Импортировать набор «{name}» в профиль {profile}?\n\nКонфиги профиля будут заменены, прежние останутся рядом с расширением .bak.",
|
||||
"import.done": "Пресет импортирован в профиль {profile}. Записано файлов: {files}.",
|
||||
"import.kept": "Свои значения взяты из профиля {profile}: {keys}",
|
||||
"import.sandboxPreset": "Пресет песочницы одиночной игры: {count} параметров",
|
||||
"import.sandboxPresetNote": "Значения перенесутся в песочницу профиля. Параметры модов, которых в ней ещё нет, пропускаются — такой пресет лучше импортировать после первого запуска с модами.",
|
||||
"import.applied": "Перенесено параметров: {applied}, пропущено: {skipped}",
|
||||
"mods.listTitle": "Импорт списка модов",
|
||||
"mods.listHint": "Строка из кнопки «Поделиться» в игре: «Название:ModA;ModB;…». Заменит список включённых модов — он сохранится по кнопке «Сохранить».",
|
||||
"mods.listPlaceholder": "Mymods:ModA;ModB;ModC",
|
||||
"mods.listApply": "Применить список",
|
||||
"mods.listEmpty": "В строке нет идентификаторов модов",
|
||||
"mods.listConfirm": "Заменить список включённых модов на {count} из вставленной строки?",
|
||||
"mods.listDone": "Список принят: модов {count}. Нажмите «Сохранить», чтобы записать его в конфиг.",
|
||||
"mods.listNoFiles": "Файлов не найдено у {count} модов. Чтобы сервер их скачал, добавьте коллекцию мастерской.",
|
||||
|
||||
"settings.versionTitle": "Версия панели",
|
||||
"settings.title": "Настройки менеджера",
|
||||
@@ -624,7 +635,7 @@ const STRINGS = {
|
||||
"profiles.create": "Create profile",
|
||||
|
||||
"import.title": "Import a collection preset",
|
||||
"import.fileHint": "A collection ZIP package: the panel takes the server .ini, the sandbox settings and the spawn regions out of it and skips the rest.",
|
||||
"import.fileHint": "A collection ZIP package or a .cfg sandbox preset. From the archive the panel takes the server .ini, the sandbox settings and the spawn regions, and skips the rest.",
|
||||
"import.reading": "Reading the archive…",
|
||||
"import.set": "Preset from the archive",
|
||||
"import.server": "Server: {name}",
|
||||
@@ -649,6 +660,17 @@ const STRINGS = {
|
||||
"import.confirm": "Import the preset \"{name}\" into the profile {profile}?\n\nThe profile configs will be replaced, the previous ones stay next to them with a .bak extension.",
|
||||
"import.done": "Preset imported into the profile {profile}. Files written: {files}.",
|
||||
"import.kept": "Your own values were taken from the profile {profile}: {keys}",
|
||||
"import.sandboxPreset": "Single-player sandbox preset: {count} settings",
|
||||
"import.sandboxPresetNote": "The values are transferred into the profile's sandbox. Mod settings that are not there yet are skipped — such a preset is best imported after the first start with the mods.",
|
||||
"import.applied": "Settings transferred: {applied}, skipped: {skipped}",
|
||||
"mods.listTitle": "Import a mod list",
|
||||
"mods.listHint": "The line from the game's Share button: \"Name:ModA;ModB;…\". It replaces the list of enabled mods — press Save to write it into the config.",
|
||||
"mods.listPlaceholder": "Mymods:ModA;ModB;ModC",
|
||||
"mods.listApply": "Apply the list",
|
||||
"mods.listEmpty": "The line has no mod identifiers",
|
||||
"mods.listConfirm": "Replace the list of enabled mods with the {count} from the pasted line?",
|
||||
"mods.listDone": "List accepted: {count} mods. Press Save to write it into the config.",
|
||||
"mods.listNoFiles": "No files found for {count} mods. Add the Workshop collection so the server downloads them.",
|
||||
|
||||
"settings.versionTitle": "Panel version",
|
||||
"settings.title": "Manager settings",
|
||||
|
||||
Reference in New Issue
Block a user