From 83784d5a350168edaade4620122c2c6d46bc81a2 Mon Sep 17 00:00:00 2001 From: mat Date: Thu, 14 Sep 2023 16:48:21 -0500 Subject: rename Local to LocalEntity --- azalea-entity/src/plugin/indexing.rs | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'azalea-entity/src/plugin/indexing.rs') diff --git a/azalea-entity/src/plugin/indexing.rs b/azalea-entity/src/plugin/indexing.rs index eb874437..a8ea9d85 100644 --- a/azalea-entity/src/plugin/indexing.rs +++ b/azalea-entity/src/plugin/indexing.rs @@ -13,7 +13,7 @@ use nohash_hasher::IntMap; use std::{collections::HashMap, fmt::Debug}; use uuid::Uuid; -use crate::{EntityUuid, LastSentPosition, Local, Position}; +use crate::{EntityUuid, LastSentPosition, LocalEntity, Position}; use super::LoadedBy; @@ -87,7 +87,7 @@ pub fn deduplicate_entities( mut commands: Commands, mut query: Query< (Entity, &MinecraftEntityId, &InstanceName), - (Changed, Without), + (Changed, Without), >, mut loaded_by_query: Query<&mut LoadedBy>, mut entity_id_index_query: Query<&mut EntityIdIndex>, @@ -141,7 +141,7 @@ pub fn deduplicate_local_entities( mut commands: Commands, mut query: Query< (Entity, &MinecraftEntityId, &InstanceName), - (Changed, With), + (Changed, With), >, instance_container: Res, ) { @@ -169,7 +169,7 @@ pub fn deduplicate_local_entities( pub fn update_uuid_index( mut entity_infos: ResMut, - query: Query<(Entity, &EntityUuid, Option<&Local>), Changed>, + query: Query<(Entity, &EntityUuid, Option<&LocalEntity>), Changed>, ) { for (entity, &uuid, local) in query.iter() { // only add it if it doesn't already exist in @@ -189,7 +189,12 @@ pub fn update_uuid_index( /// System to keep the entity_by_id index up-to-date. pub fn update_entity_by_id_index( mut query: Query< - (Entity, &MinecraftEntityId, &InstanceName, Option<&Local>), + ( + Entity, + &MinecraftEntityId, + &InstanceName, + Option<&LocalEntity>, + ), Changed, >, instance_container: Res, -- cgit v1.2.3