diff options
| author | mat <github@matdoes.dev> | 2022-05-07 21:58:10 -0500 |
|---|---|---|
| committer | mat <github@matdoes.dev> | 2022-05-07 21:58:10 -0500 |
| commit | ff79c1838add53ecf10e9e2783cdcaba122f1650 (patch) | |
| tree | b8992d3f17f9fc074d705a9eb7ae41d2ffee30e9 /azalea-protocol | |
| parent | ffba10185401ebdbfd93b1181eda04ce08fa72d5 (diff) | |
| download | azalea-drasl-ff79c1838add53ecf10e9e2783cdcaba122f1650.tar.xz | |
level event packet
Diffstat (limited to 'azalea-protocol')
| -rw-r--r-- | azalea-protocol/src/packets/game/clientbound_level_event_packet.rs | 10 | ||||
| -rwxr-xr-x | azalea-protocol/src/packets/game/mod.rs | 4 |
2 files changed, 13 insertions, 1 deletions
diff --git a/azalea-protocol/src/packets/game/clientbound_level_event_packet.rs b/azalea-protocol/src/packets/game/clientbound_level_event_packet.rs new file mode 100644 index 00000000..b8572a85 --- /dev/null +++ b/azalea-protocol/src/packets/game/clientbound_level_event_packet.rs @@ -0,0 +1,10 @@ +use azalea_core::BlockPos; +use packet_macros::GamePacket; + +#[derive(Clone, Debug, GamePacket)] +pub struct ClientboundLevelEventPacket { + pub type_: i32, + pub pos: BlockPos, + pub data: i32, + pub global_event: bool, +} diff --git a/azalea-protocol/src/packets/game/mod.rs b/azalea-protocol/src/packets/game/mod.rs index 031e95f7..c9000913 100755 --- a/azalea-protocol/src/packets/game/mod.rs +++ b/azalea-protocol/src/packets/game/mod.rs @@ -1,3 +1,4 @@ +pub mod clientbound_level_event_packet; pub mod clientbound_add_entity_packet; pub mod clientbound_add_mob_packet; pub mod clientbound_add_player_packet; @@ -63,6 +64,7 @@ declare_state_packets!( 0x20: clientbound_initialize_border_packet::ClientboundInitializeBorderPacket, 0x21: clientbound_keep_alive_packet::ClientboundKeepAlivePacket, 0x22: clientbound_level_chunk_with_light_packet::ClientboundLevelChunkWithLightPacket, + 0x23: clientbound_level_event_packet::ClientboundLevelEventPacket, 0x25: clientbound_light_update_packet::ClientboundLightUpdatePacket, 0x26: clientbound_login_packet::ClientboundLoginPacket, 0x29: clientbound_move_entity_pos_packet::ClientboundMoveEntityPosPacket, @@ -91,4 +93,4 @@ declare_state_packets!( 0x66: clientbound_update_recipes_packet::ClientboundUpdateRecipesPacket, 0x67: clientbound_update_tags_packet::ClientboundUpdateTagsPacket, } -); +);
\ No newline at end of file |
