diff options
Diffstat (limited to 'azalea-protocol/src')
6 files changed, 11 insertions, 9 deletions
diff --git a/azalea-protocol/src/packets/game/clientbound_add_entity_packet.rs b/azalea-protocol/src/packets/game/clientbound_add_entity_packet.rs index 75f3f4dc..0f2686e6 100755 --- a/azalea-protocol/src/packets/game/clientbound_add_entity_packet.rs +++ b/azalea-protocol/src/packets/game/clientbound_add_entity_packet.rs @@ -1,7 +1,7 @@ use azalea_buf::McBuf; use azalea_core::{ResourceLocation, Vec3}; +use azalea_entity::{metadata::apply_default_metadata, EntityBundle}; use azalea_protocol_macros::ClientboundGamePacket; -use azalea_world::entity::{metadata::apply_default_metadata, EntityBundle}; use uuid::Uuid; #[derive(Clone, Debug, McBuf, ClientboundGamePacket)] diff --git a/azalea-protocol/src/packets/game/clientbound_add_player_packet.rs b/azalea-protocol/src/packets/game/clientbound_add_player_packet.rs index 4cbeb1b9..45ab4584 100755 --- a/azalea-protocol/src/packets/game/clientbound_add_player_packet.rs +++ b/azalea-protocol/src/packets/game/clientbound_add_player_packet.rs @@ -1,8 +1,8 @@ use azalea_buf::McBuf; use azalea_core::{ResourceLocation, Vec3}; +use azalea_entity::{metadata::PlayerMetadataBundle, EntityBundle, PlayerBundle}; use azalea_protocol_macros::ClientboundGamePacket; use azalea_registry::EntityKind; -use azalea_world::entity::{metadata::PlayerMetadataBundle, EntityBundle, PlayerBundle}; use uuid::Uuid; /// This packet is sent by the server when a player comes into visible range, diff --git a/azalea-protocol/src/packets/game/clientbound_level_particles_packet.rs b/azalea-protocol/src/packets/game/clientbound_level_particles_packet.rs index 6efe1f97..7cae607e 100755 --- a/azalea-protocol/src/packets/game/clientbound_level_particles_packet.rs +++ b/azalea-protocol/src/packets/game/clientbound_level_particles_packet.rs @@ -1,5 +1,5 @@ use azalea_buf::{BufReadError, McBufReadable, McBufVarReadable, McBufVarWritable, McBufWritable}; -use azalea_core::ParticleData; +use azalea_core::particle::ParticleData; use azalea_protocol_macros::ClientboundGamePacket; use std::io::{Cursor, Write}; diff --git a/azalea-protocol/src/packets/game/clientbound_set_entity_data_packet.rs b/azalea-protocol/src/packets/game/clientbound_set_entity_data_packet.rs index d133eeea..7d869650 100755 --- a/azalea-protocol/src/packets/game/clientbound_set_entity_data_packet.rs +++ b/azalea-protocol/src/packets/game/clientbound_set_entity_data_packet.rs @@ -1,6 +1,6 @@ use azalea_buf::McBuf; +use azalea_entity::EntityMetadataItems; use azalea_protocol_macros::ClientboundGamePacket; -use azalea_world::entity::EntityMetadataItems; #[derive(Clone, Debug, McBuf, ClientboundGamePacket)] pub struct ClientboundSetEntityDataPacket { diff --git a/azalea-protocol/src/packets/game/clientbound_update_attributes_packet.rs b/azalea-protocol/src/packets/game/clientbound_update_attributes_packet.rs index 4c24ba64..1468a77f 100755 --- a/azalea-protocol/src/packets/game/clientbound_update_attributes_packet.rs +++ b/azalea-protocol/src/packets/game/clientbound_update_attributes_packet.rs @@ -1,7 +1,7 @@ use azalea_buf::McBuf; use azalea_core::ResourceLocation; +use azalea_entity::attributes::AttributeModifier; use azalea_protocol_macros::ClientboundGamePacket; -use azalea_world::entity::attributes::AttributeModifier; #[derive(Clone, Debug, McBuf, ClientboundGamePacket)] pub struct ClientboundUpdateAttributesPacket { diff --git a/azalea-protocol/src/packets/game/clientbound_update_recipes_packet.rs b/azalea-protocol/src/packets/game/clientbound_update_recipes_packet.rs index 8c24bdbe..7acffb7a 100755 --- a/azalea-protocol/src/packets/game/clientbound_update_recipes_packet.rs +++ b/azalea-protocol/src/packets/game/clientbound_update_recipes_packet.rs @@ -221,10 +221,12 @@ impl McBufWritable for Recipe { impl McBufReadable for Recipe { fn read_from(buf: &mut Cursor<&[u8]>) -> Result<Self, BufReadError> { let recipe_serializer_name = ResourceLocation::read_from(buf)?; - let Ok(recipe_serializer) = - RecipeSerializer::from_str(&recipe_serializer_name.to_string()) else { - return Err(BufReadError::UnexpectedStringEnumVariant { id: recipe_serializer_name.to_string() }); - }; + let Ok(recipe_serializer) = RecipeSerializer::from_str(&recipe_serializer_name.to_string()) + else { + return Err(BufReadError::UnexpectedStringEnumVariant { + id: recipe_serializer_name.to_string(), + }); + }; let identifier = ResourceLocation::read_from(buf)?; // rust doesn't let us match ResourceLocation so we have to do a big |
