Locale files now support &-code formatting used by many plugins

This commit is contained in:
nossr50 2019-01-21 07:40:04 -08:00
parent e8c8f8b6a1
commit c728b233e6
3 changed files with 25 additions and 1 deletions

View File

@ -9,6 +9,7 @@ Key:
Version 2.1.0
+ mcMMO now features XP bars! Configurable in experience.yml
+ Locale files now support & codes for colors and formatting!
+ Prevented exploits involving blocks made from entities (snowmen, etc..)
+ Added JSON integration to all Skill Commands
+ Added config setting to enable or disable old mcMMO skill scaling (General.RetroMode) this is on by default for existing installs

View File

@ -114,6 +114,29 @@ public final class LocaleLoader {
input = input.replaceAll("\\Q[[MAGIC]]\\E", ChatColor.MAGIC.toString());
input = input.replaceAll("\\Q[[RESET]]\\E", ChatColor.RESET.toString());
input = input.replaceAll("\\Q&0\\E", ChatColor.BLACK.toString());
input = input.replaceAll("\\Q&1\\E", ChatColor.DARK_BLUE.toString());
input = input.replaceAll("\\Q&2\\E", ChatColor.DARK_GREEN.toString());
input = input.replaceAll("\\Q&3\\E", ChatColor.DARK_AQUA.toString());
input = input.replaceAll("\\Q&4\\E", ChatColor.DARK_RED.toString());
input = input.replaceAll("\\Q&5\\E", ChatColor.DARK_PURPLE.toString());
input = input.replaceAll("\\Q&6\\E", ChatColor.GOLD.toString());
input = input.replaceAll("\\Q&7\\E", ChatColor.GRAY.toString());
input = input.replaceAll("\\Q&8\\E", ChatColor.DARK_GRAY.toString());
input = input.replaceAll("\\Q&9\\E", ChatColor.BLUE.toString());
input = input.replaceAll("\\Q&a\\E", ChatColor.GREEN.toString());
input = input.replaceAll("\\Q&b\\E", ChatColor.AQUA.toString());
input = input.replaceAll("\\Q&c\\E", ChatColor.RED.toString());
input = input.replaceAll("\\Q&d\\E", ChatColor.LIGHT_PURPLE.toString());
input = input.replaceAll("\\Q&e\\E", ChatColor.YELLOW.toString());
input = input.replaceAll("\\Q&f\\E", ChatColor.WHITE.toString());
input = input.replaceAll("\\Q&l\\E", ChatColor.BOLD.toString());
input = input.replaceAll("\\Q&n\\E", ChatColor.UNDERLINE.toString());
input = input.replaceAll("\\Q&o\\E", ChatColor.ITALIC.toString());
input = input.replaceAll("\\Q&m\\E", ChatColor.STRIKETHROUGH.toString());
input = input.replaceAll("\\Q&?\\E", ChatColor.MAGIC.toString());
input = input.replaceAll("\\Q&r\\E", ChatColor.RESET.toString());
return input;
}
}

View File

@ -136,7 +136,7 @@ Acrobatics.SubSkill.GracefulRoll.Description=Twice as effective as a normal Roll
Acrobatics.SubSkill.Dodge.Name=Dodge
Acrobatics.SubSkill.Dodge.Description=Reduce attack damage by half
Acrobatics.Listener=Acrobatics:
Acrobatics.Roll.Text=**Rolled**
Acrobatics.Roll.Text=[[ITALIC]][[BOLD]]**Rolled**
Acrobatics.SkillName=ACROBATICS
#ALCHEMY
Alchemy.SubSkill.Catalysis.Name=Catalysis