diff --git a/src/main/java/com/gamingmesh/jobs/Signs/SignUtil.java b/src/main/java/com/gamingmesh/jobs/Signs/SignUtil.java index 60c6e208..07a5910c 100644 --- a/src/main/java/com/gamingmesh/jobs/Signs/SignUtil.java +++ b/src/main/java/com/gamingmesh/jobs/Signs/SignUtil.java @@ -16,6 +16,7 @@ import org.bukkit.configuration.file.YamlConfiguration; import com.gamingmesh.jobs.Jobs; import com.gamingmesh.jobs.config.CommentedYamlConfiguration; import com.gamingmesh.jobs.container.TopList; +import com.gamingmesh.jobs.stuff.Debug; public class SignUtil { @@ -154,35 +155,35 @@ public class SignUtil { String PlayerNameStrip = PlayerName.split("(?<=\\G.{7})")[0]; PlayerName = PlayerNameStrip + "~"; } - String line1 = Jobs.getLanguage().getMessage("signs.SpecialList." + one.GetNumber() + ".1"); - line1 = line1.replace("[number]", String.valueOf(one.GetNumber() + number + 1)); - line1 = line1.replace("[player]", PlayerName); - line1 = line1.replace("[level]", String.valueOf(PlayerList.get(0).getLevel())); - line1 = line1.replace("[job]", JobName); + String line1 = Jobs.getLanguage().getMessage("signs.SpecialList.p" + one.GetNumber(), + "[number]", one.GetNumber() + number + 1, + "[player]", PlayerName, + "[level]", PlayerList.get(0).getLevel(), + "[job]", JobName); sign.setLine(0, line1); - line1 = Jobs.getLanguage().getMessage("signs.SpecialList." + one.GetNumber() + ".2"); - line1 = line1.replace("[number]", String.valueOf(one.GetNumber() + number + 1)); - line1 = line1.replace("[player]", PlayerName); - line1 = line1.replace("[level]", String.valueOf(PlayerList.get(0).getLevel())); - line1 = line1.replace("[job]", JobName); + line1 = Jobs.getLanguage().getMessage("signs.SpecialList.name", + "[number]", one.GetNumber() + number + 1, + "[player]", PlayerName, + "[level]", PlayerList.get(0).getLevel(), + "[job]", JobName); sign.setLine(1, line1); - line1 = Jobs.getLanguage().getMessage("signs.SpecialList." + one.GetNumber() + ".3"); - line1 = line1.replace("[number]", String.valueOf(one.GetNumber() + number + 1)); - line1 = line1.replace("[player]", PlayerName); - line1 = line1.replace("[level]", String.valueOf(PlayerList.get(0).getLevel())); - line1 = line1.replace("[job]", JobName); + line1 = Jobs.getLanguage().getMessage("signs.SpecialList.level", + "[number]", one.GetNumber() + number + 1, + "[player]", PlayerName, + "[level]", PlayerList.get(0).getLevel(), + "[job]", JobName); sign.setLine(2, line1); - line1 = Jobs.getLanguage().getMessage("signs.SpecialList." + one.GetNumber() + ".4"); - line1 = line1.replace("[number]", String.valueOf(one.GetNumber() + number + 1)); - line1 = line1.replace("[player]", PlayerName); - line1 = line1.replace("[level]", String.valueOf(PlayerList.get(0).getLevel())); - line1 = line1.replace("[job]", JobName); + line1 = Jobs.getLanguage().getMessage("signs.SpecialList.bottom", + "[number]", one.GetNumber() + number + 1, + "[player]", PlayerName, + "[level]", PlayerList.get(0).getLevel(), + "[job]", JobName); sign.setLine(3, line1); sign.update(); diff --git a/src/main/java/com/gamingmesh/jobs/config/LanguageManager.java b/src/main/java/com/gamingmesh/jobs/config/LanguageManager.java index 13d586ff..132c49a6 100644 --- a/src/main/java/com/gamingmesh/jobs/config/LanguageManager.java +++ b/src/main/java/com/gamingmesh/jobs/config/LanguageManager.java @@ -495,18 +495,19 @@ public class LanguageManager { c.get("message.crafting.fullinventory", "Your inventory is full!"); c.get("signs.List", "&0[number].&8[player]&7:&4[level]"); - c.get("signs.SpecialList.1.1", "&b** &8First &b**"); - c.get("signs.SpecialList.1.2", "&9[player]"); - c.get("signs.SpecialList.1.3", "&8[level] level"); - c.get("signs.SpecialList.1.4", "&b************"); - c.get("signs.SpecialList.2.1", "&b** &8Second &b**"); - c.get("signs.SpecialList.2.2", "&9[player]"); - c.get("signs.SpecialList.2.3", "&8[level] level"); - c.get("signs.SpecialList.2.4", "&b************"); - c.get("signs.SpecialList.3.1", "&b** &8Third &b**"); - c.get("signs.SpecialList.3.2", "&9[player]"); - c.get("signs.SpecialList.3.3", "&8[level] level"); - c.get("signs.SpecialList.3.4", "&b************"); + c.get("signs.SpecialList.p1", "&b** &8First &b**"); + c.get("signs.SpecialList.p2", "&b** &8Second &b**"); + c.get("signs.SpecialList.p3", "&b** &8Third &b**"); + c.get("signs.SpecialList.p4", "&b** &8Fourth &b**"); + c.get("signs.SpecialList.p5", "&b** &8Fifth &b**"); + c.get("signs.SpecialList.p6", "&b** &8Sixth &b**"); + c.get("signs.SpecialList.p7", "&b** &8Seventh &b**"); + c.get("signs.SpecialList.p8", "&b** &8Eight &b**"); + c.get("signs.SpecialList.p9", "&b** &8Ninth &b**"); + c.get("signs.SpecialList.p10", "&b** &8Tenth &b**"); + c.get("signs.SpecialList.name", "&9[player]"); + c.get("signs.SpecialList.level", "&8[level] level"); + c.get("signs.SpecialList.bottom", "&b************"); c.get("signs.cantcreate", "&4You can't create this sign!"); c.get("signs.cantdestroy", "&4You can't destroy this sign!"); c.get("signs.topline", "&0[Jobs]"); diff --git a/src/main/java/com/gamingmesh/jobs/i18n/Language.java b/src/main/java/com/gamingmesh/jobs/i18n/Language.java index 0c5139f3..6d27f632 100644 --- a/src/main/java/com/gamingmesh/jobs/i18n/Language.java +++ b/src/main/java/com/gamingmesh/jobs/i18n/Language.java @@ -54,7 +54,7 @@ public class Language { } public String getMessage(String key, Object... variables) { - String missing = "Missing locale for " + key + " "; + String missing = "MLF " + key; String msg = ""; try { if (customlocale == null || !customlocale.contains(key))