mirror of
https://github.com/Minestom/Minestom.git
synced 2025-02-05 06:51:22 +01:00
Temporarily fix inventories
This commit is contained in:
parent
1b5bf59c26
commit
4ba85b4ff3
@ -120,10 +120,7 @@ public class NbtReaderUtils {
|
||||
String stringName = reader.readShortSizedString();
|
||||
|
||||
if (stringName.equals("Name")) {
|
||||
String jsonDisplayName = reader.readShortSizedString();
|
||||
Component textObject = Chat.fromJsonString(jsonDisplayName);
|
||||
String displayName = Chat.toLegacyText(textObject);
|
||||
item.setDisplayName(displayName);
|
||||
item.setDisplayName(reader.readShortSizedString());
|
||||
readItemStackDisplayNBT(reader, item);
|
||||
}
|
||||
break;
|
||||
@ -137,11 +134,7 @@ public class NbtReaderUtils {
|
||||
int size = reader.readInteger();
|
||||
ArrayList<String> lore = new ArrayList<>(size);
|
||||
for (int i = 0; i < size; i++) {
|
||||
String string = reader.readShortSizedString();
|
||||
|
||||
Component textObject = Chat.fromJsonString(string);
|
||||
String line = Chat.toLegacyText(textObject);
|
||||
lore.add(line);
|
||||
lore.add(reader.readShortSizedString());
|
||||
if (lore.size() == size) {
|
||||
item.setLore(lore);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user