aboutsummaryrefslogtreecommitdiff
path: root/azalea-nbt/src/encode.rs
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-nbt/src/encode.rs')
-rwxr-xr-xazalea-nbt/src/encode.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/azalea-nbt/src/encode.rs b/azalea-nbt/src/encode.rs
index fb5585b3..17d20270 100755
--- a/azalea-nbt/src/encode.rs
+++ b/azalea-nbt/src/encode.rs
@@ -217,3 +217,10 @@ impl Tag {
self.write(&mut encoder)
}
}
+
+impl McBufWritable for Tag {
+ fn write_into(&self, buf: &mut impl Write) -> Result<(), std::io::Error> {
+ self.write(buf)
+ .map_err(|e| std::io::Error::new(std::io::ErrorKind::Other, e.to_string()))
+ }
+}