aboutsummaryrefslogtreecommitdiff
path: root/azalea-protocol/src
diff options
context:
space:
mode:
Diffstat (limited to 'azalea-protocol/src')
-rw-r--r--azalea-protocol/src/packets/game/clientbound_update_mob_effect_packet.rs16
-rwxr-xr-xazalea-protocol/src/packets/game/mod.rs2
2 files changed, 18 insertions, 0 deletions
diff --git a/azalea-protocol/src/packets/game/clientbound_update_mob_effect_packet.rs b/azalea-protocol/src/packets/game/clientbound_update_mob_effect_packet.rs
new file mode 100644
index 00000000..5a446c2f
--- /dev/null
+++ b/azalea-protocol/src/packets/game/clientbound_update_mob_effect_packet.rs
@@ -0,0 +1,16 @@
+use azalea_buf::McBuf;
+use packet_macros::GamePacket;
+
+#[derive(Clone, Debug, McBuf, GamePacket)]
+pub struct ClientboundUpdateMobEffectPacket {
+ #[var]
+ pub entity_id: u32,
+ // TODO: have an enum for this
+ #[var]
+ pub effect: u32,
+ pub effect_amplifier: u8,
+ #[var]
+ pub effect_duration_ticks: u32,
+ pub flags: u8,
+ pub factor_data: Option<azalea_nbt::Tag>,
+}
diff --git a/azalea-protocol/src/packets/game/mod.rs b/azalea-protocol/src/packets/game/mod.rs
index 3e492dec..f407a697 100755
--- a/azalea-protocol/src/packets/game/mod.rs
+++ b/azalea-protocol/src/packets/game/mod.rs
@@ -46,6 +46,7 @@ pub mod clientbound_system_chat_packet;
pub mod clientbound_teleport_entity_packet;
pub mod clientbound_update_advancements_packet;
pub mod clientbound_update_attributes_packet;
+pub mod clientbound_update_mob_effect_packet;
pub mod clientbound_update_recipes_packet;
pub mod clientbound_update_tags_packet;
pub mod clientbound_update_view_distance_packet;
@@ -124,6 +125,7 @@ declare_state_packets!(
0x63: clientbound_teleport_entity_packet::ClientboundTeleportEntityPacket,
0x64: clientbound_update_advancements_packet::ClientboundUpdateAdvancementsPacket,
0x65: clientbound_update_attributes_packet::ClientboundUpdateAttributesPacket,
+ 0x66: clientbound_update_mob_effect_packet::ClientboundUpdateMobEffectPacket,
0x67: clientbound_update_recipes_packet::ClientboundUpdateRecipesPacket,
0x68: clientbound_update_tags_packet::ClientboundUpdateTagsPacket,
}