mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-23 17:37:45 +01:00
SPIGOT-4363: Bad colours in leather armor
This commit is contained in:
parent
953e1d601a
commit
1cead6280f
@ -36,7 +36,11 @@ class CraftMetaLeatherArmor extends CraftMetaItem implements LeatherArmorMeta {
|
||||
if (tag.hasKey(DISPLAY.NBT)) {
|
||||
NBTTagCompound display = tag.getCompound(DISPLAY.NBT);
|
||||
if (display.hasKey(COLOR.NBT)) {
|
||||
color = Color.fromRGB(display.getInt(COLOR.NBT));
|
||||
try {
|
||||
color = Color.fromRGB(display.getInt(COLOR.NBT));
|
||||
} catch (IllegalArgumentException ex) {
|
||||
// Invalid colour
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user