WorldGuard-Translator
无需再为翻译 WorldGuard 而烦恼。使用此插件,您可以轻松翻译并自定义 WorldGuard 插件的消息,而无需修改 JAR 文件(例如使用 InJarTranslator)。

(查看当前翻译列表)
? 功能特性
- 高性能且轻量级
- 支持 MiniMessage 格式
- 在游戏中直接修改消息
- 将英文动作键(例如
break that block)翻译为您自己的语言
- 兼容任意版本的 WorldGuard
- 自动下载预设的翻译内容
⠀
? 插件工作原理
WorldGuard-Translator 会在服务器启动或插件重载期间,直接在 RAM 中修改 WorldGuard 的代码。
该插件会拦截原始的拒绝消息(deny-message),并将英文技术字符串动态替换为您翻译后的等效内容。
⠀
✍️ 配置说明
config.yml
# 预设的 WorldGuard 翻译内容。
# 从 https://github.com/SuperCHIROK1/WorldGuard-Translator/tree/main/translations 下载
# 您只需自定义消息样式以适配您的服务器即可。
# 您可以添加自己的语言。在 "translations" 文件夹内创建一个文件,并将其命名为 <language>.yml 格式。
#
# 在此处检查最新的翻译内容:https://github.com/SuperCHIROK1/WorldGuard-Translator/tree/main/translations
# 插件构建时可用的语言:
#: English (en)
#: Russian (ru)
#: French (fr) - By @git-jamesfrench
lang: en
# WorldGuard-Translator 插件消息的前缀。
# 用于本地消息,通过 %prefix% 替换
prefix: "bafb6&l[WG-Translator]&f"
# 文本格式化序列化器。
#
#: LEGACY_AMPERSAND - 传统的传统颜色代码(例如 &c, &l)
#: MINI_MESSAGE - 现代 MiniMessage 格式(Paper 1.18+)
# 了解更多格式信息请访问:https://docs.papermc.io/adventure/minimessage/format/
serializer: LEGACY_AMPERSAND
# 检查 WorldGuard-Translator 插件更新。
# 如果有可用更新,插件将在控制台和聊天中通知管理员。
check_updates: true
# 权限设置。
permissions:
admin_command: "wgtranslator.admin"
update_log: "wgtranslator.update"
本地化文件示例 (en.yml)
# 拒绝消息模板。
# %what% 会自动被 "components" 部分中的翻译字符串替换。
deny_message: "&#ff5400&l❌ Hey! &fSorry, but you cannot &#ff5400%what% &fhere!"
# 特定动作的翻译。
# 插入到 deny_message 中的 %what% 位置。
# 您可以使用 /wgt component add <key>;<value> 添加自己的翻译
components:
# 放置方块
"place that block": "place blocks"
"place fire": "ignite the ground"
"use frostwalker": "use Frost Walker"
# 破坏方块
"break that block": "break blocks"
"use dynamite": "use dynamite"
# 方块/实体交互
"use that": "use this"
"open that": "open this"
"sleep": "go to sleep"
"use anchors": "use respawn anchor"
"use explosives": "use explosives"
# 实体生成/掉落
"place things": "place items"
"place vehicles": "place vehicles"
"drop items": "drop items"
"drop XP": "drop XP"
"use lingering potions": "use lingering potions"
# 实体销毁/拾取
"break things": "break items"
"break vehicles": "break vehicles"
"pick up items": "pick up items"
# 实体伤害/骑乘
"change that": "modify this"
"ride that": "ride this"
"hit that": "attack this"
"damage that": "damage this"
"harm that": "harm this"
"PvP": "fight players"
messages:
reloaded: "%prefix% Fe000Plugin successfully reloaded! &#e2eafcNew messages/translations have been applied to WorldGuard. &7(Time: %s ms.)"
deny_message:
installed: "%prefix% Fe000Successfully set deny_message!"
installed_temp: "%prefix% Fe000Successfully set temporary deny_message &7(lasts until server or plugin restart)"
component:
added: "%prefix% Fe000Successfully added translation: bafb6%s &#a1a8b8-> bafb6%s"
usage: "%prefix% &#e2eafcPlease use the format bafb6<key>;<translation>&#e2eafc. Example: bafb6break that block;break blocks"
list:
header: "&#a1a8b8----- bafb6&lWG-T : Components &#a1a8b8-----\n"
# {0} - key | {1} - translation
format: "&#a1a8b8• bafb6{0} &#a1a8b8-> &#e2eafc{1}"
help: |-
&8----- &3&lWorldGuard Translator &8-----
&8• &e/%cmd% &6<reload | restart> &7- &#e2eafcReload the plugin.
&8• &e/%cmd% &6component <add | set | list> &7- &#e2eafcManage translations.
&8• &e/%cmd% &6denyMessage <set | setTemp> &7- &#e2eafcSet deny_message.
⠀
?️ 命令与权限
⚠️ 要使用以下列出的任何命令,您必须拥有 wgtranslator.admin 权限(或在配置文件中指定的自定义权限)。
| 命令 |
参数 |
描述 |
/wgt |
reload / restart / r |
完全重新加载插件配置 |
/wgt |
help |
显示包含可用命令的帮助菜单 |
/wgt component |
add / set <key>;<value> |
添加或更新特定动作的翻译 |
/wgt component |
list |
在聊天中列出当前所有已翻译的字符串 |
/wgt denyMessage |
set <message> |
设置全局 denyMessage 模板 |
/wgt denyMessage |
setTemp <message> |
设置临时 denyMessage,直到下次服务器/插件重启前有效 |
⠀
❤️ 支持本项目:
⠀
⚠️ 发现错误或需要帮助?
加入我们的 Discord 服务器!
在这里,你可以提问、报告错误、提出新想法,或提交你自己的翻译。
WorldGuard-Translator
Forget about the hassle of translating WorldGuard. With this plugin, you can easily translate and customize messages from the WorldGuard plugin without modifying the JAR file, for example, using InJarTranslator.

(View the current list of translations)
? Features
- High performance and lightweight
- MiniMessage formatting support
- Modify messages directly in-game
- Translation of English action keys (e.g.,
break that block) to your own language
- Compatibility with any WorldGuard version
- Automatic downloading of pre-made translations
⠀
? How does the plugin work?
WorldGuard-Translator modifies WorldGuard's code directly in RAM during server startup or plugin reload.
The plugin intercepts the original deny messages (deny-message) and dynamically replaces English technical strings with your translated equivalents.
⠀
✍️ Configurations
config.yml
# Pre-made WorldGuard translations.
# Downloaded from https://github.com/SuperCHIROK1/WorldGuard-Translator/tree/main/translations
# All you need to do is customize the message style to fit your server.
# You can add your own languages. Create a file inside "translations" folder and name it in <language>.yml format.
#
# Check for the latest translations here: https://github.com/SuperCHIROK1/WorldGuard-Translator/tree/main/translations
# Languages available at the time of the plugin build:
#: English (en)
#: Russian (ru)
#: French (fr) - By @git-jamesfrench
lang: en
# Prefix for WorldGuard-Translator plugin messages.
# Used in local messages, replaced via %prefix%
prefix: "bafb6&l[WG-Translator]&f"
# Text formatting serializer.
#
#: LEGACY_AMPERSAND - Traditional legacy color codes (e.g., &c, &l)
#: MINI_MESSAGE - Modern MiniMessage formatting (Paper 1.18+)
# Learn more about formatting here: https://docs.papermc.io/adventure/minimessage/format/
serializer: LEGACY_AMPERSAND
# Check for WorldGuard-Translator plugin updates.
# If an update is available, the plugin will notify administrators in the console and chat.
check_updates: true
# Permission settings.
permissions:
admin_command: "wgtranslator.admin"
update_log: "wgtranslator.update"
Example of localization file (en.yml)
# Deny message template.
# %what% is automatically replaced with the translated string from the "components" section.
deny_message: "&#ff5400&l❌ Hey! &fSorry, but you cannot &#ff5400%what% &fhere!"
# Translations of specific actions.
# Inserted instead of %what% in deny_message.
# You can add your own translations using /wgt component add <key>;<value>
components:
# Block place
"place that block": "place blocks"
"place fire": "ignite the ground"
"use frostwalker": "use Frost Walker"
# Block break
"break that block": "break blocks"
"use dynamite": "use dynamite"
# Block / entity interact
"use that": "use this"
"open that": "open this"
"sleep": "go to sleep"
"use anchors": "use respawn anchor"
"use explosives": "use explosives"
# Entity spawn / drop
"place things": "place items"
"place vehicles": "place vehicles"
"drop items": "drop items"
"drop XP": "drop XP"
"use lingering potions": "use lingering potions"
# Entity destroy / pickup
"break things": "break items"
"break vehicles": "break vehicles"
"pick up items": "pick up items"
# Entity damage / mount
"change that": "modify this"
"ride that": "ride this"
"hit that": "attack this"
"damage that": "damage this"
"harm that": "harm this"
"PvP": "fight players"
messages:
reloaded: "%prefix% Fe000Plugin successfully reloaded! &#e2eafcNew messages/translations have been applied to WorldGuard. &7(Time: %s ms.)"
deny_message:
installed: "%prefix% Fe000Successfully set deny_message!"
installed_temp: "%prefix% Fe000Successfully set temporary deny_message &7(lasts until server or plugin restart)"
component:
added: "%prefix% Fe000Successfully added translation: bafb6%s &#a1a8b8-> bafb6%s"
usage: "%prefix% &#e2eafcPlease use the format bafb6<key>;<translation>&#e2eafc. Example: bafb6break that block;break blocks"
list:
header: "&#a1a8b8----- bafb6&lWG-T : Components &#a1a8b8-----\n"
# {0} - key | {1} - translation
format: "&#a1a8b8• bafb6{0} &#a1a8b8-> &#e2eafc{1}"
help: |-
&8----- &3&lWorldGuard Translator &8-----
&8• &e/%cmd% &6<reload | restart> &7- &#e2eafcReload the plugin.
&8• &e/%cmd% &6component <add | set | list> &7- &#e2eafcManage translations.
&8• &e/%cmd% &6denyMessage <set | setTemp> &7- &#e2eafcSet deny_message.
⠀
?️ Commands & Permissions
⚠️ To use any of the commands listed below, you must have the wgtranslator.admin permission (or the custom one you specified in the configuration file).
| Command |
Arguments |
Description |
/wgt |
reload / restart / r |
Reloads the plugin configuration completely |
/wgt |
help |
Displays the help menu with available commands |
/wgt component |
add / set <key>;<value> |
Adds or updates a translation for a specific action |
/wgt component |
list |
Lists all currently translated strings in chat |
/wgt denyMessage |
set <message> |
Sets the global denyMessage template |
/wgt denyMessage |
setTemp <message> |
Sets a temporary denyMessage until the next server/plugin restart |
⠀
❤️ Support the Project:
⠀
⚠️ Found a bug or need assistance?
Join our Discord server!
Here you can ask questions, report bugs, suggest new ideas, or submit your own translations.
评论 0
登录后参与评分
还没有评论,来抢沙发吧