mirror of
https://github.com/EngineHub/WorldGuard.git
synced 2024-06-26 14:34:53 +02:00
Formatting fixes.
This commit is contained in:
parent
82451595cb
commit
18365bbe42
|
@ -442,6 +442,7 @@ private void appendStringFlagValue(TextComponent.Builder builder, StringFlag fla
|
|||
} else {
|
||||
final TextComponent defComp = LegacyComponentSerializer.INSTANCE.deserialize(defVal);
|
||||
String display = reduceToText(defComp);
|
||||
display = display.replace("\n", "\\n");
|
||||
if (display.length() > 23) {
|
||||
display = display.substring(0, 20) + "...";
|
||||
}
|
||||
|
@ -451,6 +452,7 @@ private void appendStringFlagValue(TextComponent.Builder builder, StringFlag fla
|
|||
} else {
|
||||
TextComponent currComp = LegacyComponentSerializer.INSTANCE.deserialize(currVal);
|
||||
String display = reduceToText(currComp);
|
||||
display = display.replace("\n", "\\n");
|
||||
if (display.length() > 23) {
|
||||
display = display.substring(0, 20) + "...";
|
||||
}
|
||||
|
|
|
@ -41,7 +41,7 @@ public static void sendStringToTitle(LocalPlayer player, String message) {
|
|||
String title = CommandUtils.replaceColorMacros(parts[0]);
|
||||
title = WorldGuard.getInstance().getPlatform().getMatcher().replaceMacros(player, title);
|
||||
if (parts.length > 1) {
|
||||
String subtitle = CommandUtils.replaceColorMacros(parts[0]);
|
||||
String subtitle = CommandUtils.replaceColorMacros(parts[1]);
|
||||
subtitle = WorldGuard.getInstance().getPlatform().getMatcher().replaceMacros(player, subtitle);
|
||||
player.sendTitle(title, subtitle);
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue
Block a user