aboutsummaryrefslogtreecommitdiff
path: root/azalea
diff options
context:
space:
mode:
Diffstat (limited to 'azalea')
-rw-r--r--azalea/examples/nearest_entity.rs4
-rw-r--r--azalea/src/bot.rs5
-rw-r--r--azalea/src/nearest_entity.rs4
-rw-r--r--azalea/src/pathfinder/mod.rs4
-rw-r--r--azalea/src/pathfinder/simulation.rs2
5 files changed, 10 insertions, 9 deletions
diff --git a/azalea/examples/nearest_entity.rs b/azalea/examples/nearest_entity.rs
index 22a8b863..2105d29e 100644
--- a/azalea/examples/nearest_entity.rs
+++ b/azalea/examples/nearest_entity.rs
@@ -3,7 +3,7 @@ use azalea::ClientBuilder;
use azalea::{Bot, LookAtEvent};
use azalea_client::Account;
use azalea_entity::metadata::{ItemItem, Player};
-use azalea_entity::{EyeHeight, Local, Position};
+use azalea_entity::{EyeHeight, LocalEntity, Position};
use bevy_app::{FixedUpdate, Plugin};
use bevy_ecs::{
prelude::{Entity, EventWriter},
@@ -30,7 +30,7 @@ impl Plugin for LookAtStuffPlugin {
}
fn look_at_everything(
- bots: Query<Entity, (With<Local>, With<Player>)>,
+ bots: Query<Entity, (With<LocalEntity>, With<Player>)>,
entities: EntityFinder,
entity_positions: Query<(&Position, Option<&EyeHeight>)>,
mut look_at_event: EventWriter<LookAtEvent>,
diff --git a/azalea/src/bot.rs b/azalea/src/bot.rs
index 353ec99f..4c2a7a21 100644
--- a/azalea/src/bot.rs
+++ b/azalea/src/bot.rs
@@ -13,7 +13,8 @@ use azalea_client::mining::Mining;
use azalea_client::TickBroadcast;
use azalea_core::{BlockPos, Vec3};
use azalea_entity::{
- clamp_look_direction, metadata::Player, EyeHeight, Jumping, Local, LookDirection, Position,
+ clamp_look_direction, metadata::Player, EyeHeight, Jumping, LocalEntity, LookDirection,
+ Position,
};
use azalea_physics::PhysicsSet;
use bevy_app::{FixedUpdate, Update};
@@ -52,7 +53,7 @@ pub struct Bot {
#[allow(clippy::type_complexity)]
fn insert_bot(
mut commands: Commands,
- mut query: Query<Entity, (Without<Bot>, With<Local>, With<Player>)>,
+ mut query: Query<Entity, (Without<Bot>, With<LocalEntity>, With<Player>)>,
) {
for entity in &mut query {
commands.entity(entity).insert(Bot::default());
diff --git a/azalea/src/nearest_entity.rs b/azalea/src/nearest_entity.rs
index b9db6adb..38c9886e 100644
--- a/azalea/src/nearest_entity.rs
+++ b/azalea/src/nearest_entity.rs
@@ -18,14 +18,14 @@ use bevy_ecs::{
/// use azalea::chat::SendChatEvent;
/// use azalea::nearest_entity::EntityFinder;
/// use azalea_entity::metadata::{Player, AbstractMonster};
-/// use azalea_entity::Local;
+/// use azalea_entity::LocalEntity;
/// use bevy_ecs::system::Query;
/// use bevy_ecs::prelude::{Entity, EventWriter};
/// use bevy_ecs::query::With;
///
/// /// All bots near aggressive mobs will scream in chat.
/// pub fn bots_near_aggressive_mobs(
-/// bots: Query<Entity, (With<Local>, With<Player>)>,
+/// bots: Query<Entity, (With<LocalEntity>, With<Player>)>,
/// entity_finder: EntityFinder<With<AbstractMonster>>,
/// mut chat_events: EventWriter<SendChatEvent>,
/// ) {
diff --git a/azalea/src/pathfinder/mod.rs b/azalea/src/pathfinder/mod.rs
index eab292ec..dbaa57a2 100644
--- a/azalea/src/pathfinder/mod.rs
+++ b/azalea/src/pathfinder/mod.rs
@@ -20,7 +20,7 @@ use azalea_client::movement::walk_listener;
use azalea_client::{StartSprintEvent, StartWalkEvent};
use azalea_core::BlockPos;
use azalea_entity::metadata::Player;
-use azalea_entity::Local;
+use azalea_entity::LocalEntity;
use azalea_entity::{Physics, Position};
use azalea_physics::PhysicsSet;
use azalea_world::{InstanceContainer, InstanceName};
@@ -73,7 +73,7 @@ pub struct Pathfinder {
#[allow(clippy::type_complexity)]
fn add_default_pathfinder(
mut commands: Commands,
- mut query: Query<Entity, (Without<Pathfinder>, With<Local>, With<Player>)>,
+ mut query: Query<Entity, (Without<Pathfinder>, With<LocalEntity>, With<Player>)>,
) {
for entity in &mut query {
commands.entity(entity).insert(Pathfinder::default());
diff --git a/azalea/src/pathfinder/simulation.rs b/azalea/src/pathfinder/simulation.rs
index a61b823f..4f179795 100644
--- a/azalea/src/pathfinder/simulation.rs
+++ b/azalea/src/pathfinder/simulation.rs
@@ -83,7 +83,7 @@ impl Simulation {
.spawn((
MinecraftEntityId(0),
InstanceName(instance_name),
- azalea_entity::Local,
+ azalea_entity::LocalEntity,
azalea_entity::Jumping::default(),
azalea_entity::LookDirection::default(),
Sprinting(true),