diff --git a/azalea-client/src/connect.rs b/azalea-client/src/connect.rs index d28f2067..826bce3d 100755 --- a/azalea-client/src/connect.rs +++ b/azalea-client/src/connect.rs @@ -252,6 +252,9 @@ impl Client { GamePacket::ClientboundEntityVelocityPacket(p) => { println!("Got entity velocity packet {:?}", p); } + GamePacket::ClientboundSetEntityLinkPacket(p) => { + println!("Got set entity link packet {:?}", p); + } _ => panic!("Unexpected packet {:?}", packet), } println!(); diff --git a/azalea-protocol/src/packets/game/clientbound_entity_velocity_packet.rs b/azalea-protocol/src/packets/game/clientbound_entity_velocity_packet.rs index 83b21425..94061c51 100644 --- a/azalea-protocol/src/packets/game/clientbound_entity_velocity_packet.rs +++ b/azalea-protocol/src/packets/game/clientbound_entity_velocity_packet.rs @@ -1,10 +1,4 @@ -use async_trait::async_trait; -use azalea_chat::component::Component; -use azalea_core::{resource_location::ResourceLocation, Slot}; -use packet_macros::{GamePacket, McBufReadable, McBufWritable}; -use tokio::io::AsyncRead; - -use crate::mc_buf::{McBufReadable, McBufWritable, Readable, Writable}; +use packet_macros::GamePacket; #[derive(Clone, Debug, GamePacket)] pub struct ClientboundEntityVelocityPacket { diff --git a/azalea-protocol/src/packets/game/clientbound_set_entity_link_packet.rs b/azalea-protocol/src/packets/game/clientbound_set_entity_link_packet.rs new file mode 100644 index 00000000..7ee4a43c --- /dev/null +++ b/azalea-protocol/src/packets/game/clientbound_set_entity_link_packet.rs @@ -0,0 +1,7 @@ +use packet_macros::GamePacket; + +#[derive(Clone, Debug, GamePacket)] +pub struct ClientboundSetEntityLinkPacket { + pub source_id: u32, + pub dest_id: u32, +} diff --git a/azalea-protocol/src/packets/game/mod.rs b/azalea-protocol/src/packets/game/mod.rs index 22b65bff..bdba6d2b 100755 --- a/azalea-protocol/src/packets/game/mod.rs +++ b/azalea-protocol/src/packets/game/mod.rs @@ -16,6 +16,7 @@ pub mod clientbound_recipe_packet; pub mod clientbound_set_carried_item_packet; pub mod clientbound_set_chunk_cache_center; pub mod clientbound_set_entity_data_packet; +pub mod clientbound_set_entity_link_packet; pub mod clientbound_update_attributes_packet; pub mod clientbound_update_recipes_packet; pub mod clientbound_update_tags_packet; @@ -48,6 +49,7 @@ declare_state_packets!( 0x49: clientbound_set_chunk_cache_center::ClientboundSetChunkCacheCenterPacket, 0x4a: clientbound_update_view_distance_packet::ClientboundUpdateViewDistancePacket, 0x4d: clientbound_set_entity_data_packet::ClientboundSetEntityDataPacket, + 0x45: clientbound_set_entity_link_packet::ClientboundSetEntityLinkPacket, 0x4f: clientbound_entity_velocity_packet::ClientboundEntityVelocityPacket, 0x64: clientbound_update_attributes_packet::ClientboundUpdateAttributesPacket, 0x66: clientbound_update_recipes_packet::ClientboundUpdateRecipesPacket,