Implemented 0x12-ClientboundContainerSetContentPacket, 0x14-ClientboundContainerSetSlotPacket, implemented slot data codec

This commit is contained in:
2026-09-11 01:19:59 +08:00
parent 7c22cdd158
commit 59189d2fad
69 files changed
+3146 -67

No files matched your search

@@ -80,6 +80,7 @@ public fun NBTInput.readNetworkCompound(): NBTCompound {
return when (val type = NBTType.fromID(readByte().toInt() and 0xFF)) {
NBTType.Compound -> NBTCompound("", readCompoundTag())
NBTType.String -> NBTCompound("", NBTTag.CompoundTag(linkedMapOf("text" to NBTTag.StringTag(readStringTag()))))
NBTType.End -> NBTCompound("", NBTTag.CompoundTag(linkedMapOf()))
else -> throw UnsupportedOperationException("Unsupported network nbt tag 0x${type.id.toString(16).uppercase()}")
}
}