From dc2e8fb9ae21da0aa5883f041b10ebdbe53e37e2 Mon Sep 17 00:00:00 2001 From: Mixpa <514518274@qq.com> Date: Sat, 10 Aug 2019 11:52:37 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/locale/en.yml | 2 +- src/main/resources/locale/zh_CN.yml | 64 +++++++++++++++++++++++++++++ 2 files changed, 65 insertions(+), 1 deletion(-) create mode 100644 src/main/resources/locale/zh_CN.yml diff --git a/src/main/resources/locale/en.yml b/src/main/resources/locale/en.yml index 5f253f8..7e42dd7 100644 --- a/src/main/resources/locale/en.yml +++ b/src/main/resources/locale/en.yml @@ -61,4 +61,4 @@ prestige: not-high-enough: "&cYou cannot prestige at your rank!" not-in-ladder: "&cSorry, but we could not find any rankups for the group(s) you are in. Use /ranks to list the rankups." -invalid-rankup: "Invalid rankup defined in config, please check console." \ No newline at end of file +invalid-rankup: "&cInvalid rankup defined in config, please check console." \ No newline at end of file diff --git a/src/main/resources/locale/zh_CN.yml b/src/main/resources/locale/zh_CN.yml new file mode 100644 index 0000000..40602d9 --- /dev/null +++ b/src/main/resources/locale/zh_CN.yml @@ -0,0 +1,64 @@ +# the messages in this section can be customised for each rankup in rankups.yml. +rankup: + requirements-not-met: "&c 你还需要 {MONEY} 才能够升级。" + no-rankup: "&e你已经处在最高的等级了。" + # set to an empty string, ie: success-public: "" + # to hide that message. + success-public: "&a玩家 {PLAYER} &e升级到: &d{RANK}" + success-private: "&a你已经升级到: &d{RANK}" + # used for the text confirmation + confirmation: |- + &e你确定要升级到 &a{RANK}&e? + &e再次输入 &c/rankup &e来确定。 + # used for the GUI confirmation + title: "升级到 {RANK}" + + must-prestige: "&cYou must prestige to /rankup further!" + + # you can (and probably should) you override these in rankups.yml + # to show the specific requirements for each rank. + # however if you are just using money or don't need to change the message per rank, you can use any combination of: + # {MONEY} {MONEY_NEEDED} {PERCENT_DONE } {PERCENT_LEFT } {AMOUNT } {AMOUNT_NEEDED } + # {MONEY} and {MONEY_NEEDED} are different from {AMOUNT money} and {AMOUNT_NEEDED money} in that they use a different format. + # here is an example of showing the requirements for just money: + #list: + # complete: "&7{OLD_RANK} &8\xbb &7{RANK} &efor &7${MONEY}" + # current: "&c{OLD_RANK} &e\xbb &c{RANK} &efor &a${MONEY} &e{PERCENT_DONE money}%" + # incomplete: "&r{OLD_RANK} &e\xbb &r{RANK} &efor &a${MONEY}" + list: + complete: "&7{OLD_RANK} &8\xbb &7{RANK}" + current: "&c{OLD_RANK} &e\xbb &c{RANK}" + incomplete: "&r{OLD_RANK} &e\xbb &r{RANK}" + # an empty string disables the header/footer + header: "" + footer: "" + # sent when a player tries to rankup when they are on cooldown + cooldown: + singular: "&c你必须等候 {SECONDS_LEFT} 才能够再次升级!" + plural: "&c你必须等候 {SECONDS_LEFT} 才能够再次升级!" +# prestige messages can also be customised +prestige: + requirements-not-met: "&cYou need {MONEY} money to prestige." + no-prestige: "&eYou are at the highest prestige." + + success-public: "&a{PLAYER} &ehas prestiged to: &d{RANK}" + success-private: "&aYou have prestiged to: &d{RANK}" + + confirmation: |- + &eAre you sure you want to prestige to &a{RANK}&e? + &eType &c/prestige &eagain to confirm. + title: "Prestige to {RANK}" + + list: + complete: "&7{OLD_RANK} &8\xbb &7{RANK}" + current: "&c{OLD_RANK} &e\xbb &c{RANK}" + incomplete: "&r{OLD_RANK} &e\xbb &r{RANK}" + header: "" + footer: "" + cooldown: + singular: "&cYou must wait {SECONDS_LEFT} second to prestige again." + plural: "&cYou must wait {SECONDS_LEFT} more seconds to prestige again." + +not-high-enough: "&cYou cannot prestige at your rank!" +not-in-ladder: "&cSorry, but we could not find any rankups for the group(s) you are in. 使用 /ranks 指令去查看所有等级的列表。" +invalid-rankup: "&c配置中定义的等级无效,请联系管理员检查后台。" \ No newline at end of file From b84ed152591e8ed629e10bd3129bd3a73cef5b23 Mon Sep 17 00:00:00 2001 From: Mixpa <514518274@qq.com> Date: Sat, 10 Aug 2019 11:57:31 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/sh/okx/rankup/Rankup.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/sh/okx/rankup/Rankup.java b/src/main/java/sh/okx/rankup/Rankup.java index b57a7a6..92d7ecd 100644 --- a/src/main/java/sh/okx/rankup/Rankup.java +++ b/src/main/java/sh/okx/rankup/Rankup.java @@ -198,6 +198,7 @@ public class Rankup extends JavaPlugin { saveLocale("en"); saveLocale("pt-br"); saveLocale("ru"); + saveLocale("zh_CN"); } private void saveLocale(String locale) {