aboutsummaryrefslogtreecommitdiff
path: root/azalea-entity
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2023-09-18 23:25:18 -0500
committermat <git@matdoes.dev>2023-09-18 23:25:22 -0500
commit51963990bc0cbbbca388b2ed015fd64ff6492d7b (patch)
treea06f6b78f6f3954c230a9c57050467bb20ebe232 /azalea-entity
parente6941b6a24deed617d09c6e08ba65278bb3bcf25 (diff)
downloadazalea-drasl-51963990bc0cbbbca388b2ed015fd64ff6492d7b.tar.xz
fix entities not always being despawned after merge
Diffstat (limited to 'azalea-entity')
-rw-r--r--azalea-entity/src/plugin/indexing.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/azalea-entity/src/plugin/indexing.rs b/azalea-entity/src/plugin/indexing.rs
index a8ea9d85..d2049b6e 100644
--- a/azalea-entity/src/plugin/indexing.rs
+++ b/azalea-entity/src/plugin/indexing.rs
@@ -126,7 +126,7 @@ pub fn deduplicate_entities(
info!(
"Entity with id {id:?} / {new_entity:?} already existed in the world, merging it with {old_entity:?}"
);
- break;
+ continue;
}
} else {
error!("Entity was inserted into a world that doesn't exist.");
@@ -309,6 +309,6 @@ pub fn remove_despawned_entities_from_indexes(
// and now remove the entity from the ecs
commands.entity(entity).despawn();
debug!("Despawned entity {entity:?} because it was not loaded by anything.");
- return;
+ continue;
}
}