mirror of
https://github.com/mat-1/azalea.git
synced 2025-08-02 06:16:04 +00:00
don't error on bad entity data packet
This commit is contained in:
parent
c4843b347d
commit
0675e05e28
1 changed files with 5 additions and 2 deletions
|
@ -595,8 +595,11 @@ impl Client {
|
|||
ClientboundGamePacket::SetEntityData(p) => {
|
||||
debug!("Got set entity data packet {:?}", p);
|
||||
let mut dimension = client.dimension.lock();
|
||||
let mut entity = dimension.entity_mut(p.id).expect("Entity doesn't exist");
|
||||
entity.apply_metadata(&p.packed_items.0);
|
||||
if let Some(mut entity) = dimension.entity_mut(p.id) {
|
||||
entity.apply_metadata(&p.packed_items.0);
|
||||
} else {
|
||||
warn!("Server sent an entity data packet for an entity id ({}) that we don't know about", p.id);
|
||||
}
|
||||
}
|
||||
ClientboundGamePacket::UpdateAttributes(_p) => {
|
||||
// debug!("Got update attributes packet {:?}", p);
|
||||
|
|
Loading…
Add table
Reference in a new issue