From 94e563f7faeefb9bbbd601ae6e7846bacfdf0b5a Mon Sep 17 00:00:00 2001 From: Hendrix-Shen Date: Sat, 18 Jan 2025 17:14:17 +0800 Subject: [PATCH] Migrating to yamlang and rework some text Signed-off-by: Hendrix-Shen --- .../plusls/MasaGadget/SharedConstants.java | 9 + .../com/plusls/MasaGadget/game/ConfigGui.java | 2 +- .../com/plusls/MasaGadget/game/Configs.java | 138 ++++++------- .../MixinSchematicUtils.java | 2 +- .../favoritesSupport/MixinGuiConfigBase.java | 4 +- .../MixinWidgetConfigOption.java | 4 +- .../MasaGadget/util/PcaSyncProtocol.java | 2 +- .../util/SearchMobSpawnPointUtil.java | 8 +- .../assets/masa_gadget_mod/lang/en_us.json | 110 ----------- .../assets/masa_gadget_mod/lang/en_us.yml | 182 ++++++++++++++++++ .../assets/masa_gadget_mod/lang/zh_cn.json | 110 ----------- .../assets/masa_gadget_mod/lang/zh_cn.yml | 180 +++++++++++++++++ 12 files changed, 451 insertions(+), 300 deletions(-) delete mode 100644 src/main/resources/assets/masa_gadget_mod/lang/en_us.json create mode 100644 src/main/resources/assets/masa_gadget_mod/lang/en_us.yml delete mode 100644 src/main/resources/assets/masa_gadget_mod/lang/zh_cn.json create mode 100644 src/main/resources/assets/masa_gadget_mod/lang/zh_cn.yml diff --git a/src/main/java/com/plusls/MasaGadget/SharedConstants.java b/src/main/java/com/plusls/MasaGadget/SharedConstants.java index 98d0081..818d59b 100644 --- a/src/main/java/com/plusls/MasaGadget/SharedConstants.java +++ b/src/main/java/com/plusls/MasaGadget/SharedConstants.java @@ -7,6 +7,7 @@ import org.jetbrains.annotations.Contract; import org.jetbrains.annotations.NotNull; import top.hendrixshen.magiclib.api.compat.minecraft.resources.ResourceLocationCompat; +import top.hendrixshen.magiclib.api.i18n.I18n; import top.hendrixshen.magiclib.api.malilib.config.MagicConfigManager; import top.hendrixshen.magiclib.impl.malilib.config.GlobalConfigManager; import top.hendrixshen.magiclib.impl.malilib.config.MagicConfigHandler; @@ -37,4 +38,12 @@ public class SharedConstants { public static @NotNull ResourceLocation id(String path) { return ResourceLocationCompat.fromNamespaceAndPath(SharedConstants.modIdentifier, path); } + + public static String tr(String key) { + return I18n.tr(SharedConstants.modIdentifier.concat(".").concat(key)); + } + + public static String tr(String key, Object... objects) { + return I18n.tr(SharedConstants.modIdentifier.concat(".").concat(key), objects); + } } diff --git a/src/main/java/com/plusls/MasaGadget/game/ConfigGui.java b/src/main/java/com/plusls/MasaGadget/game/ConfigGui.java index 228f689..974469d 100644 --- a/src/main/java/com/plusls/MasaGadget/game/ConfigGui.java +++ b/src/main/java/com/plusls/MasaGadget/game/ConfigGui.java @@ -16,7 +16,7 @@ public ConfigGui() { super( SharedConstants.getModIdentifier(), SharedConstants.getConfigManager(), - I18n.tr("masa_gadget_mod.gui.title.configs", SharedConstants.getModVersion()) + I18n.tr("masa_gadget_mod.gui.title", SharedConstants.getModVersion()) ); } diff --git a/src/main/java/com/plusls/MasaGadget/game/Configs.java b/src/main/java/com/plusls/MasaGadget/game/Configs.java index 9dfd855..afd0e4e 100644 --- a/src/main/java/com/plusls/MasaGadget/game/Configs.java +++ b/src/main/java/com/plusls/MasaGadget/game/Configs.java @@ -60,46 +60,9 @@ public class Configs { @Config(category = ConfigCategory.GENERIC) public static MagicConfigBooleanHotkeyed renderZombieVillagerConvertTime = Configs.cf.newConfigBooleanHotkeyed("renderZombieVillagerConvertTime", false); - @Dependencies(require = @Dependency(ModId.minihud)) - @Config(category = ConfigCategory.GENERIC) - public static MagicConfigHotkey searchMobSpawnPoint = Configs.cf.newConfigHotkey("searchMobSpawnPoint"); - - @Dependencies(require = @Dependency(ModId.minihud)) - @Config(category = ConfigCategory.GENERIC) - public static MagicConfigStringList searchMobSpawnPointBlackList = Configs.cf.newConfigStringList("searchMobSpawnPointBlackList", ImmutableList.of()); - @Config(category = ConfigCategory.GENERIC) public static MagicConfigHotkey syncAllEntityData = Configs.cf.newConfigHotkey("syncAllEntityData"); - // Litematica - @Dependencies(require = @Dependency(ModId.litematica)) - @Config(category = ConfigCategory.LITEMATICA) - public static MagicConfigBooleanHotkeyed betterEasyPlaceMode = Configs.cf.newConfigBooleanHotkeyed("betterEasyPlaceMode", false); - - @Dependencies(require = @Dependency(ModId.litematica)) - @Config(category = ConfigCategory.LITEMATICA) - public static MagicConfigBooleanHotkeyed disableLitematicaEasyPlaceFailTip = Configs.cf.newConfigBooleanHotkeyed("disableLitematicaEasyPlaceFailTip", false); - - @Dependencies(require = @Dependency(ModId.litematica)) - @Config(category = ConfigCategory.LITEMATICA) - public static MagicConfigBooleanHotkeyed fixAccurateProtocol = Configs.cf.newConfigBooleanHotkeyed("fixAccurateProtocol", false); - - @Dependencies(require = { - @Dependency(value = ModId.litematica, versionPredicates = "<0.0.0-dev.20210917.192300"), - @Dependency(ModId.tweakeroo), - @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FABRIC_LIKE) - }) - @Config(category = ConfigCategory.LITEMATICA) - public static MagicConfigBoolean nudgeSelectionSupportFreeCamera = Configs.cf.newConfigBoolean("nudgeSelectionSupportFreeCamera", false); - - @Dependencies(require = @Dependency(ModId.litematica)) - @Config(category = ConfigCategory.LITEMATICA) - public static MagicConfigBoolean saveInventoryToSchematicInServer = Configs.cf.newConfigBoolean("saveInventoryToSchematicInServer", false); - - @Dependencies(require = @Dependency(ModId.litematica)) - @Config(category = ConfigCategory.LITEMATICA) - public static MagicConfigBoolean useRelativePath = Configs.cf.newConfigBoolean("useRelativePath", false); - // MALILIB @Dependencies( require = { @@ -212,38 +175,6 @@ public class Configs { @Config(category = ConfigCategory.MALILIB) public static MagicConfigDouble showOriginalConfigNameScale = Configs.cf.newConfigDouble("showOriginalConfigNameScale", 0.65, 0, 2); - // MiniHUD - @Dependencies( - require = { - @Dependency(value = ModId.minihud, versionPredicates = "<0.31.999-sakura.21"), - @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FABRIC_LIKE) - } - ) - @Dependencies( - require = { - @Dependency(value = ModId.minecraft, versionPredicates = "<1.21.1-"), - @Dependency(value = ModId.minihud, versionPredicates = "*"), - @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FORGE_LIKE) - } - ) - @Dependencies( - require = { - @Dependency(value = ModId.minecraft, versionPredicates = ">1.21.1-"), - @Dependency(value = ModId.minihud, versionPredicates = ">0.1.21-mc1.21"), - @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FORGE_LIKE) - } - ) - @Config(category = ConfigCategory.MINIHUD) - public static MagicConfigBoolean minihudI18n = Configs.cf.newConfigBoolean("minihudI18n", false); - - @Dependencies(require = { - @Dependency(ModId.minihud), - @Dependency(ModId.tweakeroo), - @Dependency(value = ModId.minecraft, versionPredicates = ">1.14.4") - }) - @Config(category = ConfigCategory.MINIHUD) - public static MagicConfigBoolean pcaSyncProtocolSyncBeehive = Configs.cf.newConfigBoolean("pcaSyncProtocolSyncBeehive", false); - // Tweakeroo @Dependencies(require = @Dependency(ModId.tweakeroo)) @Config(category = ConfigCategory.TWEAKEROO) @@ -294,6 +225,75 @@ public class Configs { @Config(category = ConfigCategory.TWEAKEROO) public static MagicConfigStringList restockWithCraftingRecipes = Configs.cf.newConfigStringList("restockWithCraftingRecipes", ImmutableList.of()); + // Litematica + @Dependencies(require = @Dependency(ModId.litematica)) + @Config(category = ConfigCategory.LITEMATICA) + public static MagicConfigBooleanHotkeyed betterEasyPlaceMode = Configs.cf.newConfigBooleanHotkeyed("betterEasyPlaceMode", false); + + @Dependencies(require = @Dependency(ModId.litematica)) + @Config(category = ConfigCategory.LITEMATICA) + public static MagicConfigBooleanHotkeyed disableLitematicaEasyPlaceFailTip = Configs.cf.newConfigBooleanHotkeyed("disableLitematicaEasyPlaceFailTip", false); + + @Dependencies(require = @Dependency(ModId.litematica)) + @Config(category = ConfigCategory.LITEMATICA) + public static MagicConfigBooleanHotkeyed fixAccurateProtocol = Configs.cf.newConfigBooleanHotkeyed("fixAccurateProtocol", false); + + @Dependencies(require = { + @Dependency(value = ModId.litematica, versionPredicates = "<0.0.0-dev.20210917.192300"), + @Dependency(ModId.tweakeroo), + @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FABRIC_LIKE) + }) + @Config(category = ConfigCategory.LITEMATICA) + public static MagicConfigBoolean nudgeSelectionSupportFreeCamera = Configs.cf.newConfigBoolean("nudgeSelectionSupportFreeCamera", false); + + @Dependencies(require = @Dependency(ModId.litematica)) + @Config(category = ConfigCategory.LITEMATICA) + public static MagicConfigBoolean saveInventoryToSchematicInServer = Configs.cf.newConfigBoolean("saveInventoryToSchematicInServer", false); + + @Dependencies(require = @Dependency(ModId.litematica)) + @Config(category = ConfigCategory.LITEMATICA) + public static MagicConfigBoolean useRelativePath = Configs.cf.newConfigBoolean("useRelativePath", false); + + // MiniHUD + @Dependencies( + require = { + @Dependency(value = ModId.minihud, versionPredicates = "<0.31.999-sakura.21"), + @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FABRIC_LIKE) + } + ) + @Dependencies( + require = { + @Dependency(value = ModId.minecraft, versionPredicates = "<1.21.1-"), + @Dependency(value = ModId.minihud, versionPredicates = "*"), + @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FORGE_LIKE) + } + ) + @Dependencies( + require = { + @Dependency(value = ModId.minecraft, versionPredicates = ">1.21.1-"), + @Dependency(value = ModId.minihud, versionPredicates = ">0.1.21-mc1.21"), + @Dependency(dependencyType = DependencyType.PLATFORM, platformType = PlatformType.FORGE_LIKE) + } + ) + @Config(category = ConfigCategory.MINIHUD) + public static MagicConfigBoolean minihudI18n = Configs.cf.newConfigBoolean("minihudI18n", false); + + @Dependencies(require = { + @Dependency(ModId.minihud), + @Dependency(ModId.tweakeroo), + @Dependency(value = ModId.minecraft, versionPredicates = ">1.14.4") + }) + @Config(category = ConfigCategory.MINIHUD) + public static MagicConfigBoolean pcaSyncProtocolSyncBeehive = Configs.cf.newConfigBoolean("pcaSyncProtocolSyncBeehive", false); + + @Dependencies(require = @Dependency(ModId.minihud)) + @Config(category = ConfigCategory.MINIHUD) + public static MagicConfigHotkey searchMobSpawnPoint = Configs.cf.newConfigHotkey("searchMobSpawnPoint"); + + @Dependencies(require = @Dependency(ModId.minihud)) + @Config(category = ConfigCategory.MINIHUD) + public static MagicConfigStringList searchMobSpawnPointBlackList = Configs.cf.newConfigStringList("searchMobSpawnPointBlackList", ImmutableList.of()); + public static void init() { Configs.cm.parseConfigClass(Configs.class); diff --git a/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/litematica/saveInventoryToSchematicInServer/MixinSchematicUtils.java b/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/litematica/saveInventoryToSchematicInServer/MixinSchematicUtils.java index 237a878..0b38b15 100644 --- a/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/litematica/saveInventoryToSchematicInServer/MixinSchematicUtils.java +++ b/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/litematica/saveInventoryToSchematicInServer/MixinSchematicUtils.java @@ -42,7 +42,7 @@ private static void syncInventory(boolean inMemoryOnly, CallbackInfoReturnable cir) { if (Configs.saveInventoryToSchematicInServer.getBooleanValue() && PcaSyncUtil.lastUpdatePos == null) { - InfoUtils.showGuiOrInGameMessage(Message.MessageType.SUCCESS, SharedConstants.getModIdentifier() + ".message.loadInventoryToLocalSuccess"); + InfoUtils.showGuiOrInGameMessage(Message.MessageType.SUCCESS, SharedConstants.tr("message.load_inventory_to_local_success")); } } } diff --git a/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinGuiConfigBase.java b/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinGuiConfigBase.java index 5383b95..e5cc97a 100644 --- a/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinGuiConfigBase.java +++ b/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinGuiConfigBase.java @@ -36,8 +36,8 @@ protected MixinGuiConfigBase(int listX, int listY) { }); SharedConstants.getConfigHandler().save(); }, - status -> status ? I18n.tr("masa_gadget_mod.message.showAllOptions") : - I18n.tr("masa_gadget_mod.message.showFavorite")); + status -> status ? SharedConstants.tr("gui.button.favorite.show_all") : + SharedConstants.tr("gui.button.favorite.show_favorite_only")); this.addWidget(favoritesButton); } } diff --git a/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinWidgetConfigOption.java b/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinWidgetConfigOption.java index c935a53..52230f2 100644 --- a/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinWidgetConfigOption.java +++ b/src/main/java/com/plusls/MasaGadget/mixin/mod_tweak/malilib/favoritesSupport/MixinWidgetConfigOption.java @@ -56,7 +56,7 @@ private void addFavoritesButton(int x, int y, float zLevel, int labelWidth, int SharedConstants.getConfigHandler().save(); }, - status -> status ? I18n.tr("masa_gadget_mod.message.cancelFavorite") : - I18n.tr("masa_gadget_mod.message.setFavorite"))); + status -> status ? SharedConstants.tr("gui.button.favorite.cancel") : + SharedConstants.tr("gui.button.favorite.set"))); } } diff --git a/src/main/java/com/plusls/MasaGadget/util/PcaSyncProtocol.java b/src/main/java/com/plusls/MasaGadget/util/PcaSyncProtocol.java index 3490ec9..915bfcc 100644 --- a/src/main/java/com/plusls/MasaGadget/util/PcaSyncProtocol.java +++ b/src/main/java/com/plusls/MasaGadget/util/PcaSyncProtocol.java @@ -297,7 +297,7 @@ public static void updateBlockEntityHandler( BlockEntity blockEntity = level.getBlockEntity(pos); if (Configs.saveInventoryToSchematicInServer.getBooleanValue() && pos.equals(PcaSyncUtil.lastUpdatePos)) { - InfoUtils.showGuiOrInGameMessage(Message.MessageType.SUCCESS, SharedConstants.getModIdentifier() + ".message.loadInventoryToLocalSuccess"); + InfoUtils.showGuiOrInGameMessage(Message.MessageType.SUCCESS, SharedConstants.tr("message.loadInventoryToLocalSuccess")); PcaSyncUtil.lastUpdatePos = null; } diff --git a/src/main/java/com/plusls/MasaGadget/util/SearchMobSpawnPointUtil.java b/src/main/java/com/plusls/MasaGadget/util/SearchMobSpawnPointUtil.java index c5ae9d1..b1f0f34 100644 --- a/src/main/java/com/plusls/MasaGadget/util/SearchMobSpawnPointUtil.java +++ b/src/main/java/com/plusls/MasaGadget/util/SearchMobSpawnPointUtil.java @@ -47,7 +47,7 @@ private static ShapeDespawnSphere getShapeDespawnSphere() { if (ret == null) { ret = (ShapeDespawnSphere) shapeBase; } else { - InfoUtil.displayChatMessage(ComponentUtil.trCompat("masa_gadget_mod.message.onlySupportOneDespawnShape") + InfoUtil.displayChatMessage(ComponentUtil.trCompat("masa_gadget_mod.message.only_support_one_despawn_shape") .withStyle(ChatFormatting.RED)); return null; } @@ -55,7 +55,7 @@ private static ShapeDespawnSphere getShapeDespawnSphere() { } if (ret == null) { - InfoUtil.displayChatMessage(ComponentUtil.trCompat("masa_gadget_mod.message.canNotFindDespawnShape") + InfoUtil.displayChatMessage(ComponentUtil.trCompat("masa_gadget_mod.message.can_not_find_respawn_shape") .withStyle(ChatFormatting.RED)); } @@ -159,11 +159,11 @@ public static void search() { MutableComponentCompat text; if (spawnPos == null) { - text = ComponentUtil.trCompat("masa_gadget_mod.message.noBlockCanSpawn") + text = ComponentUtil.trCompat("masa_gadget_mod.message.no_block_can_spawn") .withStyle(ChatFormatting.GREEN); } else { // for ommc parser - text = ComponentUtil.trCompat("masa_gadget_mod.message.spawnPos", spawnPos.getX(), spawnPos.getY(), spawnPos.getZ()); + text = ComponentUtil.trCompat("masa_gadget_mod.message.spawn_pos", spawnPos.getX(), spawnPos.getY(), spawnPos.getZ()); if (MagicLib.getInstance().getCurrentPlatform().isModLoaded(ModId.oh_my_minecraft_client)) { InfoUtil.sendCommand(String.format("highlightWaypoint %d %d %d", spawnPos.getX(), spawnPos.getY(), spawnPos.getZ())); diff --git a/src/main/resources/assets/masa_gadget_mod/lang/en_us.json b/src/main/resources/assets/masa_gadget_mod/lang/en_us.json deleted file mode 100644 index 79ae089..0000000 --- a/src/main/resources/assets/masa_gadget_mod/lang/en_us.json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "masa_gadget_mod.config.category.generic.name": "Generic", - "masa_gadget_mod.config.category.all.name": "All", - "masa_gadget_mod.config.category.litematica.name": "Litematica", - "masa_gadget_mod.config.category.malilib.name": "Malilib", - "masa_gadget_mod.config.category.minihud.name": "MiniHud", - "masa_gadget_mod.config.category.tweakeroo.name": "Tweakeroo", - "masa_gadget_mod.gui.title.configs": "MasaGadget - Config - Version: %s", - - "masa_gadget_mod.config.option.autoSyncEntityData.name": "autoSyncEntityData", - "masa_gadget_mod.config.option.autoSyncEntityData.comment": "Auto use pcaSyncProtocol to sync entity data", - "masa_gadget_mod.config.option.cacheContainerMenu.name": "cacheContainerMenu", - "masa_gadget_mod.config.option.cacheContainerMenu.comment": "Cache container menu, minecraft will cache inventory data from server when open inventory", - "masa_gadget_mod.config.option.debug.name": "debug", - "masa_gadget_mod.config.option.debug.comment": "Display debug message", - "masa_gadget_mod.config.option.openConfigGui.name": "openConfigGui", - "masa_gadget_mod.config.option.openConfigGui.comment": "A hotkey to open the in-game Config GUI", - "masa_gadget_mod.config.option.renderNextRestockTime.name": "renderNextRestockTime", - "masa_gadget_mod.config.option.renderNextRestockTime.comment": "Render next restock time on villager.", - "masa_gadget_mod.config.option.renderTradeEnchantedBook.name": "renderTradeEnchantedBook", - "masa_gadget_mod.config.option.renderTradeEnchantedBook.comment": "Render trade enchanted book text on villager.", - "masa_gadget_mod.config.option.renderVillageHomeTracer.name": "renderVillageHomeTracer", - "masa_gadget_mod.config.option.renderVillageHomeTracer.comment": "Render the tracking line of the villager to the home.", - "masa_gadget_mod.config.option.renderVillageHomeTracerColor.name": "renderVillageHomeTracerColor", - "masa_gadget_mod.config.option.renderVillageHomeTracerColor.comment": "renderVillageHomeTracer track line color.", - "masa_gadget_mod.config.option.renderVillageJobSiteTracer.name": "renderVillageJobSiteTracer", - "masa_gadget_mod.config.option.renderVillageJobSiteTracer.comment": "Render tracking line of villager to the job site.", - "masa_gadget_mod.config.option.renderVillageJobSiteTracerColor.name": "renderVillageJobSiteTracerColor", - "masa_gadget_mod.config.option.renderVillageJobSiteTracerColor.comment": "renderVillageJobSiteTracer track line color.", - "masa_gadget_mod.config.option.renderZombieVillagerConvertTime.name": "renderZombieVillagerConvertTime", - "masa_gadget_mod.config.option.renderZombieVillagerConvertTime.comment": "Render zombie villager convert time on zombie villager.", - "masa_gadget_mod.config.option.searchMobSpawnPoint.name": "searchMobSpawnPoint", - "masa_gadget_mod.config.option.searchMobSpawnPoint.comment": "Search mob spawn point. Need set §6Despawn Sphere§r in minihud, \nand light check depends on §6lightLevelThresholdSafe§r in minihud", - "masa_gadget_mod.config.option.searchMobSpawnPointBlackList.name": "searchMobSpawnPointBlackList", - "masa_gadget_mod.config.option.searchMobSpawnPointBlackList.comment": "Don't search blocks in this list.", - "masa_gadget_mod.config.option.syncAllEntityData.name": "syncAllEntityData", - "masa_gadget_mod.config.option.syncAllEntityData.comment": "Use pcaSyncProtocol to sync all entity data.", - - "masa_gadget_mod.config.option.betterEasyPlaceMode.name": "betterEasyPlaceMode", - "masa_gadget_mod.config.option.betterEasyPlaceMode.comment": "Easy place mode can open inventory (such as chest, hopper, etc.), \nand can use beacon.", - "masa_gadget_mod.config.option.disableLitematicaEasyPlaceFailTip.name": "disableLitematicaEasyPlaceFailTip", - "masa_gadget_mod.config.option.disableLitematicaEasyPlaceFailTip.comment": "Disable easyPlace failure that annoying prompt window.", - "masa_gadget_mod.config.option.fixAccurateProtocol.name": "fixAccurateProtocol", - "masa_gadget_mod.config.option.fixAccurateProtocol.comment": "Fix accurate protocol support", - "masa_gadget_mod.config.option.nudgeSelectionSupportFreeCamera.name": "nudgeSelectionSupportFreeCamera", - "masa_gadget_mod.config.option.nudgeSelectionSupportFreeCamera.comment": "Nudge Selection Support Free Camera", - "masa_gadget_mod.config.option.saveInventoryToSchematicInServer.name": "saveInventoryToSchematicInServer", - "masa_gadget_mod.config.option.saveInventoryToSchematicInServer.comment": "Use pcaSyncProtocol to sync inventory data to local and save to schematic", - "masa_gadget_mod.config.option.useRelativePath.name": "useRelativePath", - "masa_gadget_mod.config.option.useRelativePath.comment": "Save and load schematic use relative path", - - "masa_gadget_mod.config.option.backportI18nSupport.name": "backportI18nSupport", - "masa_gadget_mod.config.option.backportI18nSupport.comment": "Backport masa mod i18n support from 1.18.x", - "masa_gadget_mod.config.option.fastSwitchMasaConfigGui.name": "fastSwitchMasaConfigGui", - "masa_gadget_mod.config.option.fastSwitchMasaConfigGui.comment": "Render drop down list widget, player can switch other masa's mod config gui quickly.", - "masa_gadget_mod.config.option.favoritesSupport.name": "favoritesSupport", - "masa_gadget_mod.config.option.favoritesSupport.comment": "Users can favorite and filter their frequently used options.", - "masa_gadget_mod.config.option.fixConfigWidgetWidth.name": "fixConfigWidgetWidth", - "masa_gadget_mod.config.option.fixConfigWidgetWidth.comment": "Use the length of getTranslatedGuiDisplayName as widget width", - "masa_gadget_mod.config.option.fixConfigWidgetWidthExpand.name": "fixConfigWidgetWidthExpand", - "masa_gadget_mod.config.option.fixConfigWidgetWidthExpand.comment": "Deeper fixes for the config width label, require §6fixConfigWidgetWidth§r to be enabled.\nNote:\nMay cause additional performance overhead,\ntry enabling it only if there is a problem with config label widths,\ndisable it if it doesn't take effect", - "masa_gadget_mod.config.option.fixGetInventoryType.name": "fixGetInventoryType", - "masa_gadget_mod.config.option.fixGetInventoryType.comment": "Fix AbstractFurnaceBlock inventory type", - "masa_gadget_mod.config.option.fixSearchbarHotkeyInput.name": "fixSearchbarHotkeyInput", - "masa_gadget_mod.config.option.fixSearchbarHotkeyInput.comment": "Fix searchbar input when press hotkey to open config gui.", - "masa_gadget_mod.config.option.optimizeConfigWidgetSearch.name": "optimizeConfigWidgetSearch", - "masa_gadget_mod.config.option.optimizeConfigWidgetSearch.comment": "Make search support uppercase, translate text, and can use §6modified§r to search modified config", - "masa_gadget_mod.config.option.showOriginalConfigName.name": "showOriginalConfigName", - "masa_gadget_mod.config.option.showOriginalConfigName.comment": "Show original config name when config gui display name no the same as original config name.", - "masa_gadget_mod.config.option.showOriginalConfigNameScale.name": "showOriginalConfigNameScale", - "masa_gadget_mod.config.option.showOriginalConfigNameScale.comment": "Original config name font scale.", - - "masa_gadget_mod.config.option.minihudI18n.name": "minihudI18n", - "masa_gadget_mod.config.option.minihudI18n.comment": "Minihud display text support i18n translate.", - "masa_gadget_mod.config.option.pcaSyncProtocolSyncBeehive.name": "pcaSyncProtocolSyncBeehive", - "masa_gadget_mod.config.option.pcaSyncProtocolSyncBeehive.comment": "Press §6inventoryPreview§r hotkey to use PCA sync protocol to sync Beehive", - - "masa_gadget_mod.config.option.inventoryPreviewSupportComparator.name": "inventoryPreviewSupportComparator", - "masa_gadget_mod.config.option.inventoryPreviewSupportComparator.comment": "Inventory preview will render the output of comparator.", - "masa_gadget_mod.config.option.inventoryPreviewSupportPlayer.name": "inventoryPreviewSupportPlayer", - "masa_gadget_mod.config.option.inventoryPreviewSupportPlayer.comment": "Player can use inventory preview to show the inventory of player and ender chest inventory", - "masa_gadget_mod.config.option.inventoryPreviewSupportSelect.name": "inventoryPreviewSupportSelect", - "masa_gadget_mod.config.option.inventoryPreviewSupportSelect.comment": "When player press the inventory preview hotkey, \nplayer can use the mouse wheel to select items (player can view the enchantment information), and when player select the shulker box in the chest, player can press the mouse scroll to preview the items in the box", - "masa_gadget_mod.config.option.inventoryPreviewSupportShulkerBoxItemEntity.name": "inventoryPreviewSupportShulkerBoxItemEntity", - "masa_gadget_mod.config.option.inventoryPreviewSupportShulkerBoxItemEntity.comment": "Inventory preview support shulker box item entity.", - "masa_gadget_mod.config.option.inventoryPreviewSupportTradeOfferList.name": "inventoryPreviewSupportTradeOfferList", - "masa_gadget_mod.config.option.inventoryPreviewSupportTradeOfferList.comment": "Inventory preview will preview the trade offer list of merchant", - "masa_gadget_mod.config.option.inventoryPreviewSyncData.name": "inventoryPreviewSyncData", - "masa_gadget_mod.config.option.inventoryPreviewSyncData.comment": "When toggle inventory preview, use pcaSyncProtocol to sync block entity data and entity data from server, such as chest, villager", - "masa_gadget_mod.config.option.inventoryPreviewSyncDataClientOnly.name": "inventoryPreviewSyncDataClientOnly", - "masa_gadget_mod.config.option.inventoryPreviewSyncDataClientOnly.comment": "Open inventory to sync inventory data when use inventory preview", - "masa_gadget_mod.config.option.inventoryPreviewUseCache.name": "inventoryPreviewUseCache", - "masa_gadget_mod.config.option.inventoryPreviewUseCache.comment": "Inventory preview get the hit result from cache, to reduce lag when render", - "masa_gadget_mod.config.option.restockWithCrafting.name": "restockWithCrafting", - "masa_gadget_mod.config.option.restockWithCrafting.comment": "Automatically craft required items in the 2x2 crafting grid \nwhen Tweakeroo can't find the item. This feature requires ItemScroller。", - "masa_gadget_mod.config.option.restockWithCraftingRecipes.name": "restockWithCraftingRecipes", - "masa_gadget_mod.config.option.restockWithCraftingRecipes.comment": "Recipe indexes in ItemScroller recipe storage. Note: only 2x2 recipes are supported.", - - "masa_gadget_mod.message.canNotFindDespawnShape": "Can't find despawn shape.", - "masa_gadget_mod.message.cancelFavorite": "Cancel favorite.", - "masa_gadget_mod.message.no_data": "no data", - "masa_gadget_mod.message.loadInventoryToLocalSuccess": "Load inventory to local success", - "masa_gadget_mod.message.noBlockCanSpawn": "No block can spawn monster.", - "masa_gadget_mod.message.onlySupportOneDespawnShape": "Only support one despawn shape.", - "masa_gadget_mod.message.setFavorite": "Set favorite.", - "masa_gadget_mod.message.showAllOptions": "Show all options.", - "masa_gadget_mod.message.showFavorite": "Show favorite.", - "masa_gadget_mod.message.spawnPos": "Spawn pos: [%d, %d, %d].", - "masa_gadget_mod.message.syncAllEntityDataSuccess": "Sync all entity data success." -} diff --git a/src/main/resources/assets/masa_gadget_mod/lang/en_us.yml b/src/main/resources/assets/masa_gadget_mod/lang/en_us.yml new file mode 100644 index 0000000..1116448 --- /dev/null +++ b/src/main/resources/assets/masa_gadget_mod/lang/en_us.yml @@ -0,0 +1,182 @@ +masa_gadget_mod: + config: + category: + all: + name: All + generic: + name: Generic + litematica: + name: Litematica + malilib: + name: MaLiLib + minihud: + name: MiniHud + tweakeroo: + name: Tweakeroo + option: + # ================================ Generic ================================ + autoSyncEntityData: + name: autoSyncEntityData + comment: Auto use §7pcaSyncProtocol§r to sync entity data. + cacheContainerMenu: + name: cacheContainerMenu + comment: Will cache inventory data from server when open inventory. + debug: + name: debug + comment: Debug mode of MasaGadget. + openConfigGui: + name: openConfigGui + comment: A hotkey to open the in-game Config GUI. + renderNextRestockTime: + name: renderNextRestockTime + comment: Render next restock time on villager. + renderTradeEnchantedBook: + name: renderTradeEnchantedBook + comment: | + Render enchanted book info on villager. + Note: Only for the librarian. + renderVillageHomeTracer: + name: renderVillageHomeTracer + comment: Render tracking line of the villager to the home. + renderVillageHomeTracerColor: + name: renderVillageHomeTracerColor + comment: '@config#renderVillageHomeTracer@ track line color.' + renderVillageJobSiteTracer: + name: renderVillageJobSiteTracer + comment: Render tracking line of villager to the job site. + renderVillageJobSiteTracerColor: + name: renderVillageJobSiteTracerColor + comment: '@config#renderVillageJobSiteTracer@ track line color.' + renderZombieVillagerConvertTime: + name: renderZombieVillagerConvertTime + comment: Render convert time on zombie villager. + syncAllEntityData: + name: syncAllEntityData + comment: Use §7pcaSyncProtocol§r to sync all entity data. + # ================================ MaLiLib ================================ + backportI18nSupport: + name: backportI18nSupport + comment: Backport i18n support from MC 1.18.x + fastSwitchMasaConfigGui: + name: fastSwitchMasaConfigGui + comment: You can quickly switch between config screens using drop-down menu. + favoritesSupport: + name: favoritesSupport + comment: You can bookmark your favorite configs. + fixConfigWidgetWidth: + name: fixConfigWidgetWidth + comment: Use the length of getTranslatedGuiDisplayName as widget width + fixConfigWidgetWidthExpand: + name: fixConfigWidgetWidthExpand + comment: | + Deeper fixes for the config width label, require @config#fixConfigWidgetWidth@ to be enabled. + Note: + May cause additional performance overhead, try enabling it + only if there is a problem with config label widths, + disable it if it doesn't take effect. + fixGetInventoryType: + name: fixGetInventoryType + comment: Fix AbstractFurnaceBlock inventory type. + fixSearchbarHotkeyInput: + name: fixSearchbarHotkeyInput + comment: Fix searchbar input when press hotkey to open config gui. + optimizeConfigWidgetSearch: + name: optimizeConfigWidgetSearch + comment: Make search support uppercase, translate text, and can use §6modified§r to search modified config. + showOriginalConfigName: + name: showOriginalConfigName + comment: | + Show original config name if it was translated. + If translation does not exist it will not be displayed. + showOriginalConfigNameScale: + name: showOriginalConfigNameScale + comment: '@config#showOriginalConfigName@ font scale.' + # ================================ Tweakeroo ================================ + inventoryPreviewSupportComparator: + name: inventoryPreviewSupportComparator + comment: Inventory preview will render the output of comparator. + inventoryPreviewSupportPlayer: + name: inventoryPreviewSupportPlayer + comment: You can use preview to view the inventory of player and their ender chest inventory. + inventoryPreviewSupportSelect: + name: inventoryPreviewSupportSelect + comment: | + When you press the inventory preview hotkey, + You can use mouse wheel select item to render tooltip, + and you can switch to shulkerbox by pressing mouse wheel + when the shulkerbox is selected. + inventoryPreviewSupportShulkerBoxItemEntity: + name: inventoryPreviewSupportShulkerBoxItemEntity + comment: Inventory preview support shulker box item entity. + inventoryPreviewSupportTradeOfferList: + name: inventoryPreviewSupportTradeOfferList + comment: Inventory preview will preview the trade offer list of merchant + inventoryPreviewSyncData: + name: inventoryPreviewSyncData + comment: When you inventory preview, use §7pcaSyncProtocol§r to sync entity and block entity data and entity data from server. + inventoryPreviewSyncDataClientOnly: + name: inventoryPreviewSyncDataClientOnly + comment: Open inventory to sync block entity data. + inventoryPreviewUseCache: + name: inventoryPreviewUseCache + comment: Inventory preview get the hit result from cache, to reduce lag when render. + restockWithCrafting: + name: restockWithCrafting + comment: Automatically craft required items in the 2x2 crafting grid + restockWithCraftingRecipes: + name: restockWithCraftingRecipes + comment: | + Recipe indexes in ItemScroller recipe storage. + Note: only 2x2 recipes are supported. + # ================================ Litematica ================================ + betterEasyPlaceMode: + name: betterEasyPlaceMode + comment: Easy place mode can open container (such as chest, hopper, etc.). + disableLitematicaEasyPlaceFailTip: + name: disableLitematicaEasyPlaceFailTip + comment: Disable easyPlace failure that annoying prompt window. + fixAccurateProtocol: + name: fixAccurateProtocol + comment: Fix accurate protocol support + nudgeSelectionSupportFreeCamera: + name: nudgeSelectionSupportFreeCamera + comment: Nudge Selection Support Free Camera. + saveInventoryToSchematicInServer: + name: saveInventoryToSchematicInServer + comment: Use §7pcaSyncProtocol§r to sync inventory data to local and save to schematic. + useRelativePath: + name: useRelativePath + comment: Save and load schematic use relative path. + # ================================ MiniHud ================================ + minihudI18n: + name: minihudI18n + comment: Minihud display text support i18n translate. + pcaSyncProtocolSyncBeehive: + name: pcaSyncProtocolSyncBeehive + comment: Press §6inventoryPreview§r hotkey to use §7pcaSyncProtocol§r to sync Beehive + searchMobSpawnPoint: + name: searchMobSpawnPoint + comment: | + Search mob spawn point. Need set §6Despawn Sphere§r in minihud, + and light check depends on §66lightLevelThresholdSafe§r in minihud + searchMobSpawnPointBlackList: + name: searchMobSpawnPointBlackList + comment: Don't search blocks in this list. + gui: + title: 'MasaGadget - Version: %s' + button: + favorite: + cancel: Cancel favorite. + set: Set favorite. + show_all: Show all config. + show_favorite_only: Show favorite config only. + message: + can_not_find_respawn_shape: Can't find despawn shape. + load_inventory_to_local_success: Load inventory to local success + no_block_can_spawn: No block can spawn monster. + no_data: no data + only_support_one_despawn_shape: Only support one despawn shape. + spawn_pos: 'Spawn pos: [%d, %d, %d].' + sync_all_entity_data_success: Sync all entity data success. + + diff --git a/src/main/resources/assets/masa_gadget_mod/lang/zh_cn.json b/src/main/resources/assets/masa_gadget_mod/lang/zh_cn.json deleted file mode 100644 index 7b717c9..0000000 --- a/src/main/resources/assets/masa_gadget_mod/lang/zh_cn.json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "masa_gadget_mod.config.category.generic.name": "通用", - "masa_gadget_mod.config.category.all.name": "全部", - "masa_gadget_mod.config.category.litematica.name": "Litematica", - "masa_gadget_mod.config.category.malilib.name": "Malilib", - "masa_gadget_mod.config.category.minihud.name": "MiniHud", - "masa_gadget_mod.config.category.tweakeroo.name": "Tweakeroo", - "masa_gadget_mod.gui.title.configs": "MasaGadget 设置 - 版本: %s", - - "masa_gadget_mod.config.option.autoSyncEntityData.name": "自动同步实体数据", - "masa_gadget_mod.config.option.autoSyncEntityData.comment": "自动使用 PCA 同步协议来同步实体数据(如村民补货时间,僵尸村民转换时间,怪物是否消失)", - "masa_gadget_mod.config.option.cacheContainerMenu.name": "缓存容器数据", - "masa_gadget_mod.config.option.cacheContainerMenu.comment": "在打开容器的时候会自动缓存容器数据到本地", - "masa_gadget_mod.config.option.debug.name": "调试模式", - "masa_gadget_mod.config.option.debug.comment": "开启后将会打印调试日志", - "masa_gadget_mod.config.option.openConfigGui.name": "打开设置界面", - "masa_gadget_mod.config.option.openConfigGui.comment": "打开设置界面的快捷键", - "masa_gadget_mod.config.option.renderNextRestockTime.name": "渲染村民交易补货冷却", - "masa_gadget_mod.config.option.renderNextRestockTime.comment": "渲染距离村民下一次补货还需要多长时间", - "masa_gadget_mod.config.option.renderTradeEnchantedBook.name": "渲染村民交易的第一本附魔书", - "masa_gadget_mod.config.option.renderTradeEnchantedBook.comment": "渲染村民交易的第一本附魔书,如果是满级附魔则会显示金色文本,同时还会显示出价格,\n绿色表示良商,白色表示中商,红色表示奸商", - "masa_gadget_mod.config.option.renderVillageHomeTracer.name": "渲染村民绑定床", - "masa_gadget_mod.config.option.renderVillageHomeTracer.comment": "渲染村民到床的追踪线.", - "masa_gadget_mod.config.option.renderVillageHomeTracerColor.name": "渲染村民绑定床颜色", - "masa_gadget_mod.config.option.renderVillageHomeTracerColor.comment": "渲染村民绑定床追踪线颜色.", - "masa_gadget_mod.config.option.renderVillageJobSiteTracer.name": "渲染村民绑定工作方块", - "masa_gadget_mod.config.option.renderVillageJobSiteTracer.comment": "渲染村民到工作方块的追踪线", - "masa_gadget_mod.config.option.renderVillageJobSiteTracerColor.name": "渲染村民绑定工作方块颜色", - "masa_gadget_mod.config.option.renderVillageJobSiteTracerColor.comment": "渲染村民绑定工作方块追踪线颜色.", - "masa_gadget_mod.config.option.renderZombieVillagerConvertTime.name": "渲染僵尸村民转换时间", - "masa_gadget_mod.config.option.renderZombieVillagerConvertTime.comment": "渲染距离僵尸村民转换完成还需要多长时间", - "masa_gadget_mod.config.option.searchMobSpawnPoint.name": "搜寻可刷怪的地方", - "masa_gadget_mod.config.option.searchMobSpawnPoint.comment": "搜寻可刷怪的地方。需要在 minihud 中设置 §6怪物立刻消失范围球体§r,\n亮度检查取决于 minihud 中的 §6lightLevelThresholdSafe§r 设置", - "masa_gadget_mod.config.option.searchMobSpawnPointBlackList.name": "搜寻刷怪点黑名单", - "masa_gadget_mod.config.option.searchMobSpawnPointBlackList.comment": "在黑名单中的方块会跳过搜索", - "masa_gadget_mod.config.option.syncAllEntityData.name": "同步所有实体数据", - "masa_gadget_mod.config.option.syncAllEntityData.comment": "使用 pca 同步协议同步所有实体数据", - - "masa_gadget_mod.config.option.betterEasyPlaceMode.name": "更好的轻松放置模式", - "masa_gadget_mod.config.option.betterEasyPlaceMode.comment": "轻松放置时可以打开容器(比如箱子,漏斗等等),以及可以使用信标", - "masa_gadget_mod.config.option.disableLitematicaEasyPlaceFailTip.name": "禁用投影轻松放置失败提示", - "masa_gadget_mod.config.option.disableLitematicaEasyPlaceFailTip.comment": "禁用轻松放置失败时那烦人的提示窗", - "masa_gadget_mod.config.option.fixAccurateProtocol.name": "修复精准放置协议", - "masa_gadget_mod.config.option.fixAccurateProtocol.comment": "Litematica 本身的精准放置协议实现的有问题,修复后可以在服务器中使用轻松放置来摆放中继器,\n活塞,侦测器,楼梯等方块", - "masa_gadget_mod.config.option.nudgeSelectionSupportFreeCamera.name": "移动投影时支持 Free Camera", - "masa_gadget_mod.config.option.nudgeSelectionSupportFreeCamera.comment": "在开启 Free Camera 时,移动投影的方向会取决于 Camera 的方向", - "masa_gadget_mod.config.option.saveInventoryToSchematicInServer.name": "服务器中保存投影保留容器数据", - "masa_gadget_mod.config.option.saveInventoryToSchematicInServer.comment": "保存投影时会使用 PCA 同步协议来同步容器中的数据到本地", - "masa_gadget_mod.config.option.useRelativePath.name": "使用相对路径", - "masa_gadget_mod.config.option.useRelativePath.comment": "加载和保存投影时使用相对路径", - - "masa_gadget_mod.config.option.backportI18nSupport.name": "移植 i18n 支持", - "masa_gadget_mod.config.option.backportI18nSupport.comment": "让 masa 系 mod 支持 malilib 的 1.18.x 的 i18n 移植", - "masa_gadget_mod.config.option.fastSwitchMasaConfigGui.name": "快速切换 Masa mod 配置界面", - "masa_gadget_mod.config.option.fastSwitchMasaConfigGui.comment": "可以通过右上角的下拉菜单快速切换到别的 masa mod 的设置界面", - "masa_gadget_mod.config.option.favoritesSupport.name": "收藏夹支持", - "masa_gadget_mod.config.option.favoritesSupport.comment": "可以收藏并过滤出自己喜欢的选项", - "masa_gadget_mod.config.option.fixConfigWidgetWidth.name": "修复 Masa 配置文本的宽度", - "masa_gadget_mod.config.option.fixConfigWidgetWidth.comment": "在使用汉化包后现在的界面会根据汉化后的文本长度自动调节", - "masa_gadget_mod.config.option.fixConfigWidgetWidthExpand.name": "修复 Masa 配置文本的宽度增强", - "masa_gadget_mod.config.option.fixConfigWidgetWidthExpand.comment": "更深层修复配置文本宽度, 需要启用 §6修复 Masa 配置文本的宽度§r\n注意:\n可能带来额外的性能开销,\n仅当配置文本宽度出现问题时尝试启用,\n若不生效请关闭此功能", - "masa_gadget_mod.config.option.fixGetInventoryType.name": "修复容器类型", - "masa_gadget_mod.config.option.fixGetInventoryType.comment": "修复对烟熏炉之类的熔炉变种的容器类型的判断", - "masa_gadget_mod.config.option.fixSearchbarHotkeyInput.name": "修复搜索框按键输入", - "masa_gadget_mod.config.option.fixSearchbarHotkeyInput.comment": "修复用热键打开配置界面时会在搜索框产生错误输入的 bug", - "masa_gadget_mod.config.option.optimizeConfigWidgetSearch.name": "Masa 搜索优化", - "masa_gadget_mod.config.option.optimizeConfigWidgetSearch.comment": "在 Masa 家的搜索栏中可以使用中文搜索,还能使用 §6modified§r 来搜索修改过的配置项", - "masa_gadget_mod.config.option.showOriginalConfigName.name": "显示原始的配置选项名", - "masa_gadget_mod.config.option.showOriginalConfigName.comment": "如果当前显示的配置选项名和原始名字不一致时,在下方显示原始的配置名(英文)", - "masa_gadget_mod.config.option.showOriginalConfigNameScale.name": "显示原始的配置选项名字体大小", - "masa_gadget_mod.config.option.showOriginalConfigNameScale.comment": "原始的配置选项名字体大小", - - "masa_gadget_mod.config.option.minihudI18n.name": "Minihud 支持翻译", - "masa_gadget_mod.config.option.minihudI18n.comment": "Minihud 显示的文本可以被翻译", - "masa_gadget_mod.config.option.pcaSyncProtocolSyncBeehive.name": "PCA同步协议同步蜂巢数据", - "masa_gadget_mod.config.option.pcaSyncProtocolSyncBeehive.comment": "按下 §6容器预览§r 的快捷键将会使用 PCA 同步协议来 同步蜂巢,蜂箱数据", - - "masa_gadget_mod.config.option.inventoryPreviewSupportComparator.name": "容器预览支持比较器", - "masa_gadget_mod.config.option.inventoryPreviewSupportComparator.comment": "对比较器使用容器预览时将会显示比较器应该输出的信号", - "masa_gadget_mod.config.option.inventoryPreviewSupportPlayer.name": "容器预览支持预览玩家", - "masa_gadget_mod.config.option.inventoryPreviewSupportPlayer.comment": "对着玩家使用容器预览时,会显示出玩家背包和末影箱的内容", - "masa_gadget_mod.config.option.inventoryPreviewSupportSelect.name": "容器预览支持选中格子", - "masa_gadget_mod.config.option.inventoryPreviewSupportSelect.comment": "按下容器预览快捷键时可以使用鼠标滚轮来选中物品(可以查看附魔信息),\n在选中箱子中的潜影盒时可以按下鼠标中键来预览盒子内的物品", - "masa_gadget_mod.config.option.inventoryPreviewSupportShulkerBoxItemEntity.name": "容器预览支持潜影盒实体", - "masa_gadget_mod.config.option.inventoryPreviewSupportShulkerBoxItemEntity.comment": "容器预览支持潜影盒实体", - "masa_gadget_mod.config.option.inventoryPreviewSupportTradeOfferList.name": "容器预览显示交易列表", - "masa_gadget_mod.config.option.inventoryPreviewSupportTradeOfferList.comment": "容器预览村民时会显示出当前的交易列表", - "masa_gadget_mod.config.option.inventoryPreviewSyncData.name": "容器预览时同步数据", - "masa_gadget_mod.config.option.inventoryPreviewSyncData.comment": "容器预览时使用 PCA 同步协议来从服务器同步方块实体信息和实体信息,比如箱子内的物品,村民背包", - "masa_gadget_mod.config.option.inventoryPreviewSyncDataClientOnly.name": "容器预览时同步数据(仅客户端)", - "masa_gadget_mod.config.option.inventoryPreviewSyncDataClientOnly.comment": "容器预览时模拟开启容器来同步容器的信息", - "masa_gadget_mod.config.option.inventoryPreviewUseCache.name": "容器预览时使用缓存", - "masa_gadget_mod.config.option.inventoryPreviewUseCache.comment": "容器预览时从缓存中获取指向的方块和实体数据,从而减少渲染时的卡顿", - "masa_gadget_mod.config.option.restockWithCrafting.name": "自动补货允许 2x2 合成", - "masa_gadget_mod.config.option.restockWithCrafting.comment": "当背包内没有自动物品而 Tweakeroo 需要自动补货时,\n通过预先定义的合成表自动合成相应物品。此功能需要 ItemScroller。", - "masa_gadget_mod.config.option.restockWithCraftingRecipes.name": "自动补货合成配方", - "masa_gadget_mod.config.option.restockWithCraftingRecipes.comment": "ItemScroller 存储的配方编号,只支持 2x2 配方", - - "masa_gadget_mod.message.canNotFindDespawnShape": "找不到怪物消失图形", - "masa_gadget_mod.message.cancelFavorite": "取消收藏", - "masa_gadget_mod.message.no_data": "无数据", - "masa_gadget_mod.message.loadInventoryToLocalSuccess": "从服务同步容器数据成功", - "masa_gadget_mod.message.noBlockCanSpawn": "找不到能刷怪的方块", - "masa_gadget_mod.message.onlySupportOneDespawnShape": "只支持一个怪物消失图形", - "masa_gadget_mod.message.setFavorite": "收藏", - "masa_gadget_mod.message.showAllOptions": "显示所有配置项", - "masa_gadget_mod.message.showFavorite": "只显示收藏的配置项", - "masa_gadget_mod.message.spawnPos": "离玩家最近的能刷怪的坐标为: [%d, %d, %d]", - "masa_gadget_mod.message.syncAllEntityDataSuccess": "成功同步所有实体数据" -} diff --git a/src/main/resources/assets/masa_gadget_mod/lang/zh_cn.yml b/src/main/resources/assets/masa_gadget_mod/lang/zh_cn.yml new file mode 100644 index 0000000..491f0a9 --- /dev/null +++ b/src/main/resources/assets/masa_gadget_mod/lang/zh_cn.yml @@ -0,0 +1,180 @@ +masa_gadget_mod: + config: + category: + all: + name: 全部 + generic: + name: 通用 + litematica: + name: Litematica + malilib: + name: MaLiLib + minihud: + name: MiniHud + tweakeroo: + name: Tweakeroo + option: + # ================================ Generic ================================ + autoSyncEntityData: + name: 自动同步实体数据 + comment: 自动使用 §7pca同步协议§r 来同步实体数据。 + cacheContainerMenu: + name: 缓存容器数据 + comment: 打开容器后将缓存服务端侧数据到本地。 + debug: + name: 调试模式 + comment: MasaGadget 的调试模式。 + openConfigGui: + name: 打开配置界面 + comment: 打开配置界面的快捷键。 + renderNextRestockTime: + name: 渲染村民交易补货冷却 + comment: 在村民附近渲染下一次补货时间。 + renderTradeEnchantedBook: + name: 渲染村民交易第一本附魔书 + comment: | + 在村民附近渲染第一本附魔书的信息。 + 注意:只对图书管理员有效。 + renderVillageHomeTracer: + name: 渲染村民绑定床 + comment: 渲染村民到床的追踪线。 + renderVillageHomeTracerColor: + name: 渲染村民绑定床追踪线颜色 + comment: '@config#renderVillageHomeTracer@ 追踪线颜色。' + renderVillageJobSiteTracer: + name: 渲染村民绑定工作方块 + comment: 渲染村民绑定工作方块的追踪线。 + renderVillageJobSiteTracerColor: + name: 渲染村民绑定工作方块追踪线颜色 + comment: '@config#renderVillageJobSiteTracer@ 追踪线颜色。' + renderZombieVillagerConvertTime: + name: 渲染僵尸村民转换时间 + comment: 在僵尸村民附近渲染转换时间。 + syncAllEntityData: + name: 同步所有实体数据 + comment: 使用 §7pca同步协议§r 同步全部实体数据。 + # ================================ MaLiLib ================================ + backportI18nSupport: + name: 移植本地化支持 + comment: 从 MC 1.18.x 版本的本地化支持。 + fastSwitchMasaConfigGui: + name: 快速切换配置菜单 + comment: 你可以通过下拉菜单快速切换配置窗口。 + favoritesSupport: + name: 收藏夹支持 + comment: 你可以收藏你喜欢的配置。 + fixConfigWidgetWidth: + name: 修复配置控件宽度 + comment: 使用 getTranslatedGuiDisplayName 的长度作为配置控件的宽度。 + fixConfigWidgetWidthExpand: + name: 修复配置控件宽度增强 + comment: | + 更深层修复配置文本宽度, 需要启用 @config#fixConfigWidgetWidth@。 + 注意: + 可能带来额外的性能开销,仅当 + 配置文本宽度出现问题时尝试启用, + 若不生效请关闭此功能。 + fixGetInventoryType: + name: 修复容器类型 + comment: 修复熔炉变种容器类型的识别问题。 + fixSearchbarHotkeyInput: + name: 修复搜索框按键输入 + comment: 修复使用热键打开配置界面时会在搜索框产生错误输入的问题。 + optimizeConfigWidgetSearch: + name: 优化配置搜索 + comment: 支持忽略大小写,本地化文本,并且可以使用 §6modified§r 来搜索配置。 + showOriginalConfigName: + name: 显示原始配置名称 + comment: | + 如果配置名称被翻译,将显示原始配置名称。 + 如果翻译不存在,则不会显示。 + showOriginalConfigNameScale: + name: 显示原始配置名称缩放 + comment: '@config#showOriginalConfigName@ 字体缩放.' + # ================================ Tweakeroo ================================ + inventoryPreviewSupportComparator: + name: 容器预览支持比较器 + comment: 容器预览将渲染比较器输出信号。 + inventoryPreviewSupportPlayer: + name: 容器预览支持玩家 + comment: 你可以使用容器预览来查看玩家的背包和末影箱。 + inventoryPreviewSupportSelect: + name: 容器预览支持选中 + comment: | + 当你按住容器预览快捷键时, + 你可以使用鼠标滚轮选中物品来渲染提示窗, + 并且你可以在选中潜影盒的时候, + 按下鼠标滚轮切换潜影盒。 + inventoryPreviewSupportShulkerBoxItemEntity: + name: 容器预览支持潜影盒物品实体 + comment: 容器预览支持潜影盒实体。 + inventoryPreviewSupportTradeOfferList: + name: 容器预览支持交易列表 + comment: 容器预览将展示村民交易内容。 + inventoryPreviewSyncData: + name: 容器预览同步数据 + comment: 当进行容器预览时,使用 §7pca同步协议§r 同步实体和方块实体数据。 + inventoryPreviewSyncDataClientOnly: + name: 容器预览同步数据客户端模式 + comment: 通过打开容器的方式来同步方块实体数据。 + inventoryPreviewUseCache: + name: 容器预览使用缓存 + comment: 容器预览将使用缓存的指向结果,将减少渲染卡顿。 + restockWithCrafting: + name: 使用合成表补货 + comment: 自动使用背包 2x2 合成表合成所需物品。 + restockWithCraftingRecipes: + name: 使用合成表配方补货 + comment: | + ItemScroller 存储的配方索引。 + 注意:仅支持 2x2 配方。 + # ================================ Litematica ================================ + betterEasyPlaceMode: + name: 更好的轻松放置 + comment: 轻松放置模式可以打开容器(如箱子、漏斗等)。 + disableLitematicaEasyPlaceFailTip: + name: 禁用投影轻松放置失败提示 + comment: 禁用轻松放置失败时烦人的提示窗。 + fixAccurateProtocol: + name: 修复精准协议 + comment: 修复精准协议支持。 + nudgeSelectionSupportFreeCamera: + name: 支持自由相机移动选区 + comment: 支持自由相机模式下移动选区。 + saveInventoryToSchematicInServer: + name: 保存服务器容器数据到蓝图 + comment: 使用 §7pca同步协议§r 同步服务器容器数据来保存蓝图。 + useRelativePath: + name: 使用相对路径 + comment: 使用相对路径来存取蓝图文件。 + # ================================ MiniHud ================================ + minihudI18n: + name: MiniHud本地化 + comment: MiniHud 本地化补丁。 + pcaSyncProtocolSyncBeehive: + name: pca同步协议支持蜂巢 + comment: 按下 §6容器预览§r 热键来使用 §7pca同步协议§r 同步蜂巢。 + searchMobSpawnPoint: + name: 搜索怪物生成点 + comment: | + 搜索怪物生成点。需要再 MiniHud 中设置 §6怪物立刻消失范围球体§r, + 亮度检查取决于 MiniHud 中的 §6lightLevelThresholdSafe§r 设置。 + searchMobSpawnPointBlackList: + name: 搜寻刷怪点黑名单 + comment: 不搜索黑名单中方块。 + gui: + title: 'MasaGadget - 版本: %s' + button: + favorite: + cancel: 取消收藏。 + set: 设置收藏。 + show_all: 展示所有配置。 + show_favorite_only: 仅展示收藏配置。 + message: + can_not_find_respawn_shape: 找不到怪物消失图形。 + load_inventory_to_local_success: 从服务同步容器数据成功。 + no_block_can_spawn: 找不到能刷怪的方块。 + no_data: 无数据 + only_support_one_despawn_shape: 只支持一个怪物消失图形。 + spawn_pos: 离玩家最近的能刷怪的坐标为:[%d, %d, %d]。 + sync_all_entity_data_success: 成功同步所有实体数据。