summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authormd_5 <git@md-5.net>2018-09-16 08:30:11 +1000
committermd_5 <git@md-5.net>2018-09-16 08:30:11 +1000
commit94b8708aca2424734417b82a4e872c85740bde16 (patch)
treec4e83b6cb160f60492941331fd6f09762b41e5ce /src
parent616684369995a55b245267ffbc369616cc8c5fd0 (diff)
downloadcraftbukkit-94b8708aca2424734417b82a4e872c85740bde16.tar
craftbukkit-94b8708aca2424734417b82a4e872c85740bde16.tar.gz
craftbukkit-94b8708aca2424734417b82a4e872c85740bde16.tar.lz
craftbukkit-94b8708aca2424734417b82a4e872c85740bde16.tar.xz
craftbukkit-94b8708aca2424734417b82a4e872c85740bde16.zip
SPIGOT-4373: Item display colours are white by default
Should probably look at all this code at some point
Diffstat (limited to 'src')
-rw-r--r--src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java
index 77266427..c0ea341e 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java
@@ -50,6 +50,7 @@ import java.util.Set;
import java.util.logging.Level;
import java.util.logging.Logger;
import net.minecraft.server.ChatComponentText;
+import net.minecraft.server.EnumChatFormat;
import net.minecraft.server.NBTCompressedStreamTools;
import org.apache.commons.codec.binary.Base64;
@@ -562,7 +563,7 @@ class CraftMetaItem implements ItemMeta, Damageable, Repairable {
}
public String getDisplayName() {
- return CraftChatMessage.fromComponent(displayName);
+ return CraftChatMessage.fromComponent(displayName, EnumChatFormat.WHITE);
}
public final void setDisplayName(String name) {
@@ -575,7 +576,7 @@ class CraftMetaItem implements ItemMeta, Damageable, Repairable {
@Override
public String getLocalizedName() {
- return CraftChatMessage.fromComponent(locName);
+ return CraftChatMessage.fromComponent(locName, EnumChatFormat.WHITE);
}
@Override