fix NBT in memory optimized clipboard

This commit is contained in:
dordsor21 2021-01-06 13:29:52 +00:00
parent 91de441403
commit 280ade9994
No known key found for this signature in database
GPG Key ID: 1E53E88969FFCF0B

View File

@ -257,11 +257,11 @@ public class MemoryOptimizedClipboard extends LinearClipboard {
@Override
public boolean setTile(int x, int y, int z, CompoundTag tag) {
nbtMap.put(new IntTriple(x, y, z), tag);
Map<String, Tag> values = tag.getValue();
final Map<String, Tag> values = new HashMap<>(tag.getValue());
values.put("x", new IntTag(x));
values.put("y", new IntTag(y));
values.put("z", new IntTag(z));
nbtMap.put(new IntTriple(x, y, z), new CompoundTag(values));
return true;
}