From 8c627640b21b7273feb2378e3f51e852e55c5aaa Mon Sep 17 00:00:00 2001 From: JieningYu Date: Sun, 25 Aug 2024 11:26:29 +0800 Subject: [PATCH] shifting flags --- crates/core/block-entity/src/serde.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/crates/core/block-entity/src/serde.rs b/crates/core/block-entity/src/serde.rs index 0aa1f1a..1e5ffab 100644 --- a/crates/core/block-entity/src/serde.rs +++ b/crates/core/block-entity/src/serde.rs @@ -16,11 +16,11 @@ bitflags! { #[derive(Debug, Clone, Copy, PartialEq, Eq)] pub struct Flags: u8 { /// Serializes the registration identifier. - const ID = 0b00000001; + const ID = 1u8 << 0; /// Serializes the position. - const POS = 0b00000010; + const POS = 1u8 << 1; /// Serializes the component map. - const COMPONENTS = 0b00000100; + const COMPONENTS = 1u8 << 2; } }