diff options
| author | mat <git@matdoes.dev> | 2023-12-04 14:25:10 -0600 |
|---|---|---|
| committer | mat <git@matdoes.dev> | 2023-12-04 14:27:13 -0600 |
| commit | 797dd9171088cd697b3c95663cbbc65b05315414 (patch) | |
| tree | c179130af8172015b0d0c3b31732c77b563744a0 /azalea-client/src/packet_handling | |
| parent | 888c2765037711f45a6dac8d8bad70dc9ee70998 (diff) | |
| download | azalea-drasl-797dd9171088cd697b3c95663cbbc65b05315414.tar.xz | |
revert packet name to Disguised and make it more like ChatPacket::Player
Diffstat (limited to 'azalea-client/src/packet_handling')
| -rw-r--r-- | azalea-client/src/packet_handling/game.rs | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/azalea-client/src/packet_handling/game.rs b/azalea-client/src/packet_handling/game.rs index 6c4ea4f4..750764df 100644 --- a/azalea-client/src/packet_handling/game.rs +++ b/azalea-client/src/packet_handling/game.rs @@ -997,6 +997,18 @@ pub fn process_packet_events(ecs: &mut World) { packet: ChatPacket::System(Arc::new(p.clone())), }); } + ClientboundGamePacket::DisguisedChat(p) => { + debug!("Got disguised chat packet {p:?}"); + + let mut system_state: SystemState<EventWriter<ChatReceivedEvent>> = + SystemState::new(ecs); + let mut chat_events = system_state.get_mut(ecs); + + chat_events.send(ChatReceivedEvent { + entity: player_entity, + packet: ChatPacket::Disguised(Arc::new(p.clone())), + }); + } ClientboundGamePacket::Sound(_p) => { // debug!("Got sound packet {p:?}"); } @@ -1382,18 +1394,6 @@ pub fn process_packet_events(ecs: &mut World) { ClientboundGamePacket::TabList(_) => {} ClientboundGamePacket::TagQuery(_) => {} ClientboundGamePacket::TakeItemEntity(_) => {} - ClientboundGamePacket::MaskedChat(p) => { - debug!("Got masked chat packet {p:?}"); - - let mut system_state: SystemState<EventWriter<ChatReceivedEvent>> = - SystemState::new(ecs); - let mut chat_events = system_state.get_mut(ecs); - - chat_events.send(ChatReceivedEvent { - entity: player_entity, - packet: ChatPacket::Masked(Arc::new(p.clone())), - }); - } ClientboundGamePacket::Bundle(_) => {} ClientboundGamePacket::DamageEvent(_) => {} ClientboundGamePacket::HurtAnimation(_) => {} |
