aboutsummaryrefslogtreecommitdiff
path: root/azalea-block/src
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-block/src')
-rw-r--r--azalea-block/src/block_state.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/azalea-block/src/block_state.rs b/azalea-block/src/block_state.rs
index ab0ca076..dfa2a9b2 100644
--- a/azalea-block/src/block_state.rs
+++ b/azalea-block/src/block_state.rs
@@ -94,6 +94,12 @@ impl TryFrom<u16> for BlockState {
}
}
}
+impl From<BlockState> for u32 {
+ /// See [`BlockState::id`].
+ fn from(value: BlockState) -> Self {
+ value.id as u32
+ }
+}
impl AzaleaRead for BlockState {
fn azalea_read(buf: &mut Cursor<&[u8]>) -> Result<Self, BufReadError> {