diff options
| author | mat <git@matdoes.dev> | 2025-02-24 03:59:57 +0000 |
|---|---|---|
| committer | mat <git@matdoes.dev> | 2025-02-24 03:59:57 +0000 |
| commit | 172e0ce0793206a3cd7ae04f70beadf2e3f66c7e (patch) | |
| tree | 0a7d0d9a65fb609377921ac28844319755dc5ade /azalea-client/src/plugins/packet | |
| parent | b9767424f3393a0aed65b713e19a265189a872b0 (diff) | |
| download | azalea-drasl-172e0ce0793206a3cd7ae04f70beadf2e3f66c7e.tar.xz | |
add fallback for adding LocalEntity so tests don't fail
Diffstat (limited to 'azalea-client/src/plugins/packet')
| -rw-r--r-- | azalea-client/src/plugins/packet/config/mod.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/azalea-client/src/plugins/packet/config/mod.rs b/azalea-client/src/plugins/packet/config/mod.rs index 2e0ce354..1665997c 100644 --- a/azalea-client/src/plugins/packet/config/mod.rs +++ b/azalea-client/src/plugins/packet/config/mod.rs @@ -1,5 +1,6 @@ mod events; +use azalea_entity::LocalEntity; use azalea_protocol::packets::ConnectionProtocol; use azalea_protocol::packets::config::*; use bevy_ecs::prelude::*; @@ -108,7 +109,12 @@ impl ConfigPacketHandler<'_> { commands .entity(self.player) .remove::<InConfigState>() - .insert(crate::JoinedClientBundle::default()); + .insert(( + crate::JoinedClientBundle::default(), + // localentity should already be added, but in case the user forgot or + // something we also add it here + LocalEntity, + )); }, ); } |
