diff --git a/src/main/java/com/gmail/nossr50/commands/mc/MccCommand.java b/src/main/java/com/gmail/nossr50/commands/mc/MccCommand.java index 438ab3632..9611874ca 100644 --- a/src/main/java/com/gmail/nossr50/commands/mc/MccCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/mc/MccCommand.java @@ -1,6 +1,5 @@ package com.gmail.nossr50.commands.mc; -import org.bukkit.ChatColor; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; import org.bukkit.command.CommandSender; @@ -22,7 +21,7 @@ public class MccCommand implements CommandExecutor { Player player = (Player) sender; - player.sendMessage(ChatColor.RED + "---[]" + ChatColor.YELLOW + "mcMMO Commands" + ChatColor.RED + "[]---"); //TODO: Needs more locale. + player.sendMessage(LocaleLoader.getString("Commands.mcc.Header")); if (Permissions.party(player)) { player.sendMessage(LocaleLoader.getString("Commands.Party.Commands")); diff --git a/src/main/java/com/gmail/nossr50/commands/mc/McmmoCommand.java b/src/main/java/com/gmail/nossr50/commands/mc/McmmoCommand.java index c1f339538..6058b4b00 100644 --- a/src/main/java/com/gmail/nossr50/commands/mc/McmmoCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/mc/McmmoCommand.java @@ -23,13 +23,13 @@ public class McmmoCommand implements CommandExecutor { if (mcMMO.spoutEnabled && sender instanceof SpoutPlayer) { SpoutPlayer spoutPlayer = (SpoutPlayer) sender; - spoutPlayer.sendNotification(ChatColor.YELLOW + "[mcMMO]" + ChatColor.GOLD + " Donate!", ChatColor.GREEN + "mcmmodev@gmail.com", Material.DIAMOND); + spoutPlayer.sendNotification(LocaleLoader.getString("Spout.Donate"), ChatColor.GREEN + "gjmcferrin@gmail.com", Material.DIAMOND); } - sender.sendMessage(ChatColor.DARK_AQUA + "Donation Info:"); - sender.sendMessage(ChatColor.GOLD + " - " + ChatColor.GREEN + "mcmmodev@gmail.com" + ChatColor.GOLD + " Paypal"); + sender.sendMessage(LocaleLoader.getString("MOTD.Donate")); + sender.sendMessage(ChatColor.GOLD + " - " + ChatColor.GREEN + "gjmcferrin@gmail.com" + ChatColor.GOLD + " Paypal"); } - sender.sendMessage(ChatColor.YELLOW + "Running version: " + ChatColor.DARK_AQUA + mcMMO.p.getDescription().getVersion()); + sender.sendMessage(LocaleLoader.getString("MOTD.Version", new Object[] {mcMMO.p.getDescription().getVersion()})); Anniversary anniversary = new Anniversary(); anniversary.anniversaryCheck(sender); diff --git a/src/main/java/com/gmail/nossr50/commands/mc/McrefreshCommand.java b/src/main/java/com/gmail/nossr50/commands/mc/McrefreshCommand.java index 302007261..f85768a75 100644 --- a/src/main/java/com/gmail/nossr50/commands/mc/McrefreshCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/mc/McrefreshCommand.java @@ -1,6 +1,5 @@ package com.gmail.nossr50.commands.mc; -import org.bukkit.ChatColor; import org.bukkit.OfflinePlayer; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; @@ -24,7 +23,7 @@ public class McrefreshCommand implements CommandExecutor { public boolean onCommand(CommandSender sender, Command command, String label, String[] args) { OfflinePlayer player; PlayerProfile profile; - String usage = ChatColor.RED + "Proper usage is /mcrefresh [player]"; //TODO: Needs more locale + String usage = LocaleLoader.getString("Commands.Usage.1", new Object[] {"mcrefresh", "[" + LocaleLoader.getString("Commands.Usage.Player") + "]"}); if (CommandHelper.noCommandPermissions(sender, "mcmmo.tools.mcrefresh")) { return true; diff --git a/src/main/java/com/gmail/nossr50/commands/mc/McremoveCommand.java b/src/main/java/com/gmail/nossr50/commands/mc/McremoveCommand.java index 9fe4de1fb..e6f49db25 100644 --- a/src/main/java/com/gmail/nossr50/commands/mc/McremoveCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/mc/McremoveCommand.java @@ -5,7 +5,6 @@ import java.io.FileReader; import java.io.FileWriter; import java.io.IOException; -import org.bukkit.ChatColor; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; import org.bukkit.command.CommandSender; @@ -30,7 +29,7 @@ public class McremoveCommand implements CommandExecutor { String playerName; String tablePrefix = Config.getInstance().getMySQLTablePrefix(); //String databaseName = Config.getInstance().getMySQLDatabaseName(); - String usage = ChatColor.RED + "Proper usage is /mcremove "; //TODO: Needs more locale. + String usage = LocaleLoader.getString("Commands.Usage.1", new Object[] {"mcremove", "<" + LocaleLoader.getString("Commands.Usage.Player") + ">"}); String success; if (CommandHelper.noCommandPermissions(sender, "mcmmo.tools.mcremove")) { @@ -40,7 +39,7 @@ public class McremoveCommand implements CommandExecutor { switch (args.length) { case 1: playerName = args[0]; - success = ChatColor.GREEN + playerName + " was successfully removed from the database!"; //TODO: Locale + success = LocaleLoader.getString("Commands.mcremove.Success", new Object[] {playerName}); break; default: diff --git a/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java b/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java index ad5427c69..ba6568346 100644 --- a/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java @@ -21,7 +21,7 @@ public class MctopCommand implements CommandExecutor { @Override public boolean onCommand(CommandSender sender, Command command, String label, String[] args) { - String usage = ChatColor.RED + "Proper usage is /mctop [skill] [page]"; //TODO: Needs more locale. + String usage = LocaleLoader.getString("Commands.Usage.2", new Object[] {"mctop", "[" + LocaleLoader.getString("Commands.Usage.Skill") + "]", "[" + LocaleLoader.getString("Commands.Usage.Page") + "]"}); if (!Config.getInstance().getUseMySQL()) { @@ -145,8 +145,8 @@ public class MctopCommand implements CommandExecutor { n++; } } - - sender.sendMessage(ChatColor.GOLD+"Tip: Use "+ChatColor.RED+"/mcrank"+ChatColor.GOLD+" to view all of your personal rankings!"); + + sender.sendMessage(LocaleLoader.getString("Commands.mctop.Tip")); } private void sqlDisplay(int page, String query, CommandSender sender) { @@ -169,7 +169,7 @@ public class MctopCommand implements CommandExecutor { sender.sendMessage(String.valueOf(place) + ". " + ChatColor.GREEN + userslist.get(i).get(1) + " - " + ChatColor.WHITE + userslist.get(i).get(0)); place++; } - - sender.sendMessage(ChatColor.GOLD+"Tip: Use "+ChatColor.RED+"/mcrank"+ChatColor.GOLD+" to view all of your personal rankings!"); + + sender.sendMessage(LocaleLoader.getString("Commands.mctop.Tip")); } } diff --git a/src/main/resources/locale/locale_cy.properties b/src/main/resources/locale/locale_cy.properties index 680d206c8..8e338f10a 100644 --- a/src/main/resources/locale/locale_cy.properties +++ b/src/main/resources/locale/locale_cy.properties @@ -356,6 +356,7 @@ Commands.Inspect= [[RED]]- View detailed player info Commands.Invite.Accepted=[[GREEN]] Gwahodd Derbyniwyd. Yr ydych wedi ymuno parti {0} Commands.Invite.Success=[[GREEN]]Invite sent successfully. Commands.Leaderboards= [[RED]]- Leaderboards +Commands.mcc.Header=[[RED]]---[][[YELLOW]]mcMMO Commands[[RED]][]--- Commands.mcgod=[[RED]]- Toggle GodMode Commands.mchud.Invalid=[[RED]]That is not a valid HUD type. Commands.mcpurge.Success=[[GREEN]]The database was successfully purged! @@ -364,6 +365,8 @@ Commands.mcrank.Overall=[[YELLOW]]Overall[[GREEN]] - [[GOLD]]Rank [[WHITE]]#[[GR Commands.mcrank.Player=[[RED]]TARGET: [[WHITE]]{0} Commands.mcrank.Skill=[[YELLOW]]{0}[[GREEN]] - [[GOLD]]Rank [[WHITE]]#[[GREEN]]{1} Commands.mcrank.Unranked=[[WHITE]]Unranked +Commands.mcremove.Success=[[GREEN]]{0} was successfully removed from the database! +Commands.mctop.Tip=[[GOLD]]Tip: Use [[RED]]/mcrank[[GOLD]] to view all of your personal rankings! Commands.mmoedit=[chwaraewr] [[RED]] - Targed addasu Commands.mmoedit.Modified.1=[[GREEN]]Your level in {0} was set to {1}! Commands.mmoedit.Modified.2=[[RED]]{0} has been modified for {1}. @@ -404,6 +407,7 @@ Commands.Usage.3=[[RED]]Proper usage is /{0} {1} {2} {3} Commands.Usage.Level=level Commands.Usage.Message=message Commands.Usage.PartyName=party-name +Commands.Usage.Page=page Commands.Usage.Player=player Commands.Usage.Skill=skill Commands.Usage.XP=xp @@ -510,6 +514,7 @@ Vampirism.Killer.Failure=[[GOLD]][mcMMO] [[YELLOW]]{0}[[GRAY]] was too unskilled Vampirism.Killer.Success=[[GOLD]][mcMMO] [[DARK_AQUA]]You've stolen [[BLUE]]{0}[[DARK_AQUA]] levels from [[YELLOW]]{1}. Vampirism.Victim.Failure=[[GOLD]][mcMMO] [[YELLOW]]{0}[[GRAY]] was unable to steal knowledge from you! Vampirism.Victim.Success=[[GOLD]][mcMMO] [[YELLOW]]{0}[[DARK_RED]] has stolen [[BLUE]]{1}[[DARK_RED]] levels from you! +Spout.Donate=[[YELLOW]][mcMMO] Donate! Spout.LevelUp.1=[[GREEN]Level Up! Spout.LevelUp.2=[[YELLOW]]{0}[[DARK_AQUA]] ([[GREEN]]{1}[[DARK_AQUA]]) Spout.Menu.Exit=[[GRAY]]Press ESCAPE to exit! @@ -518,6 +523,7 @@ Spout.Menu.HudButton.1=HUD Type: {0} Spout.Menu.HudButton.2=Change your HUD style! Spout.Menu.Title=[[GOLD]]~mcMMO Menu~ Spout.Title={0}\n[[YELLOW]]P[[GOLD]]lvl[[WHITE]].[[GREEN]]{1} +MOTD.Donate=[[DARK_AQUA]]Donation Info: MOTD.Hardcore.VampireOff=[[GOLD]][mcMMO] [[DARK_RED]]Hardcore & Vampirism enabled. MOTD.Hardcore.Stats=[[GOLD]][mcMMO] [[DARK_AQUA]]Skill Death Penalty: [[DARK_RED]]{0}% MOTD.Hardcore.VampireOn=[[GOLD]][mcMMO] [[DARK_RED]]Hardcore enabled. diff --git a/src/main/resources/locale/locale_de.properties b/src/main/resources/locale/locale_de.properties index 5405a9755..d58f252b9 100644 --- a/src/main/resources/locale/locale_de.properties +++ b/src/main/resources/locale/locale_de.properties @@ -399,6 +399,7 @@ Commands.Inspect= [[RED]]- Zeigt detailierte Spielerinfos Commands.Invite.Accepted=[[GREEN]]Einladung akzeptiert. Du bist der Gruppe {0} beigetreten Commands.Invite.Success=[[GREEN]]Einladung erfolgreich versendet. Commands.Leaderboards= [[RED]]- Ranglisten +Commands.mcc.Header=[[RED]]---[][[YELLOW]]mcMMO Commands[[RED]][]--- Commands.mcgod=[[RED]]- GodMode umschalten Commands.mchud.Invalid=[[RED]]That is not a valid HUD type. Commands.mcpurge.Success=[[GREEN]]The database was successfully purged! @@ -407,6 +408,8 @@ Commands.mcrank.Overall=[[YELLOW]]Overall[[GREEN]] - [[GOLD]]Rank [[WHITE]]#[[GR Commands.mcrank.Player=[[RED]]TARGET: [[WHITE]]{0} Commands.mcrank.Skill=[[YELLOW]]{0}[[GREEN]] - [[GOLD]]Rank [[WHITE]]#[[GREEN]]{1} Commands.mcrank.Unranked=[[WHITE]]Unranked +Commands.mcremove.Success=[[GREEN]]{0} was successfully removed from the database! +Commands.mctop.Tip=[[GOLD]]Tip: Use [[RED]]/mcrank[[GOLD]] to view all of your personal rankings! Commands.mmoedit=[Spieler] [[RED]] - Ziel modifizieren Commands.mmoedit.Modified.1=[[GREEN]]Your level in {0} was set to {1}! Commands.mmoedit.Modified.2=[[RED]]{0} has been modified for {1}. @@ -449,6 +452,7 @@ Commands.Usage.2=[[RED]]Proper usage is /{0} {1} {2} Commands.Usage.3=[[RED]]Proper usage is /{0} {1} {2} {3} Commands.Usage.Level=level Commands.Usage.Message=message +Commands.Usage.Page=page Commands.Usage.PartyName=party-name Commands.Usage.Player=player Commands.Usage.Skill=skill @@ -579,6 +583,7 @@ Vampirism.Victim.Failure=[[GOLD]][mcMMO] [[YELLOW]]{0}[[GRAY]] was unable to ste Vampirism.Victim.Success=[[GOLD]][mcMMO] [[YELLOW]]{0}[[DARK_RED]] has stolen [[BLUE]]{1}[[DARK_RED]] levels from you! #SPOUT +Spout.Donate=[[YELLOW]][mcMMO] Donate! Spout.LevelUp.1=[[GREEN]Level Up! Spout.LevelUp.2=[[YELLOW]]{0}[[DARK_AQUA]] ([[GREEN]]{1}[[DARK_AQUA]]) Spout.Menu.Exit=[[GRAY]]Press ESCAPE to exit! @@ -589,6 +594,7 @@ Spout.Menu.Title=[[GOLD]]~mcMMO Menu~ Spout.Title={0}\n[[YELLOW]]P[[GOLD]]lvl[[WHITE]].[[GREEN]]{1} #MOTD +MOTD.Donate=[[DARK_AQUA]]Donation Info: MOTD.Hardcore.VampireOff=[[GOLD]][mcMMO] [[DARK_RED]]Hardcore & Vampirism enabled. MOTD.Hardcore.Stats=[[GOLD]][mcMMO] [[DARK_AQUA]]Skill Death Penalty: [[DARK_RED]]{0}% MOTD.Hardcore.VampireOn=[[GOLD]][mcMMO] [[DARK_RED]]Hardcore enabled. diff --git a/src/main/resources/locale/locale_en_US.properties b/src/main/resources/locale/locale_en_US.properties index 07e7da408..1f2529f6b 100644 --- a/src/main/resources/locale/locale_en_US.properties +++ b/src/main/resources/locale/locale_en_US.properties @@ -408,6 +408,7 @@ Commands.Inspect= [[RED]]- View detailed player info Commands.Invite.Accepted=[[GREEN]]Invite Accepted. You have joined party {0} Commands.Invite.Success=[[GREEN]]Invite sent successfully. Commands.Leaderboards= [[RED]]- Leaderboards +Commands.mcc.Header=[[RED]]---[][[YELLOW]]mcMMO Commands[[RED]][]--- Commands.mcgod=[[RED]]- Toggle GodMode Commands.mchud.Invalid=[[RED]]That is not a valid HUD type. Commands.mcpurge.Success=[[GREEN]]The database was successfully purged! @@ -416,6 +417,8 @@ Commands.mcrank.Overall=[[YELLOW]]Overall[[GREEN]] - [[GOLD]]Rank [[WHITE]]#[[GR Commands.mcrank.Player=[[RED]]TARGET: [[WHITE]]{0} Commands.mcrank.Skill=[[YELLOW]]{0}[[GREEN]] - [[GOLD]]Rank [[WHITE]]#[[GREEN]]{1} Commands.mcrank.Unranked=[[WHITE]]Unranked +Commands.mcremove.Success=[[GREEN]]{0} was successfully removed from the database! +Commands.mctop.Tip=[[GOLD]]Tip: Use [[RED]]/mcrank[[GOLD]] to view all of your personal rankings! Commands.mmoedit=[player] [[RED]] - Modify target Commands.mmoedit.Modified.1=[[GREEN]]Your level in {0} was set to {1}! Commands.mmoedit.Modified.2=[[RED]]{0} has been modified for {1}. @@ -458,6 +461,7 @@ Commands.Usage.2=[[RED]]Proper usage is /{0} {1} {2} Commands.Usage.3=[[RED]]Proper usage is /{0} {1} {2} {3} Commands.Usage.Level=level Commands.Usage.Message=message +Commands.Usage.Page=page Commands.Usage.PartyName=party-name Commands.Usage.Player=player Commands.Usage.Skill=skill @@ -588,6 +592,7 @@ Vampirism.Victim.Failure=[[GOLD]][mcMMO] [[YELLOW]]{0}[[GRAY]] was unable to ste Vampirism.Victim.Success=[[GOLD]][mcMMO] [[YELLOW]]{0}[[DARK_RED]] has stolen [[BLUE]]{1}[[DARK_RED]] levels from you! #SPOUT +Spout.Donate=[[YELLOW]][mcMMO] Donate! Spout.LevelUp.1=[[GREEN]Level Up! Spout.LevelUp.2=[[YELLOW]]{0}[[DARK_AQUA]] ([[GREEN]]{1}[[DARK_AQUA]]) Spout.Menu.Exit=[[GRAY]]Press ESCAPE to exit! @@ -598,6 +603,7 @@ Spout.Menu.Title=[[GOLD]]~mcMMO Menu~ Spout.Title={0}\n[[YELLOW]]P[[GOLD]]lvl[[WHITE]].[[GREEN]]{1} #MOTD +MOTD.Donate=[[DARK_AQUA]]Donation Info: MOTD.Hardcore.VampireOff=[[GOLD]][mcMMO] [[DARK_RED]]Hardcore & Vampirism enabled. MOTD.Hardcore.Stats=[[GOLD]][mcMMO] [[DARK_AQUA]]Skill Death Penalty: [[DARK_RED]]{0}% MOTD.Hardcore.VampireOn=[[GOLD]][mcMMO] [[DARK_RED]]Hardcore enabled.