diff options
| author | mat <27899617+mat-1@users.noreply.github.com> | 2026-01-13 10:51:30 -0600 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-01-13 10:51:30 -0600 |
| commit | d5fa5e32b37754b3b5c136e58821e48cd3b7c2ff (patch) | |
| tree | ea04702f96ad170fb1d90e5ed2dc875ae8166495 /azalea-client/src/plugins/movement.rs | |
| parent | efb36d5fc0fe56a98f5795c53dfa109887cd5aae (diff) | |
| download | azalea-drasl-d5fa5e32b37754b3b5c136e58821e48cd3b7c2ff.tar.xz | |
Rename Instance to World (#304)
Diffstat (limited to 'azalea-client/src/plugins/movement.rs')
| -rw-r--r-- | azalea-client/src/plugins/movement.rs | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/azalea-client/src/plugins/movement.rs b/azalea-client/src/plugins/movement.rs index 40cc108e..94b996a0 100644 --- a/azalea-client/src/plugins/movement.rs +++ b/azalea-client/src/plugins/movement.rs @@ -31,12 +31,12 @@ use azalea_protocol::{ }, }; use azalea_registry::builtin::EntityKind; -use azalea_world::Instance; +use azalea_world::World; use bevy_app::{App, Plugin, Update}; use bevy_ecs::prelude::*; use crate::{ - local_player::{Hunger, InstanceHolder, LocalGameMode}, + local_player::{Hunger, LocalGameMode, WorldHolder}, packet::game::SendGamePacketEvent, }; @@ -296,7 +296,7 @@ pub fn local_player_ai_step( &PlayerAbilities, &metadata::Swimming, &metadata::SleepingPos, - &InstanceHolder, + &WorldHolder, &Position, Option<&Hunger>, Option<&LastSentInput>, @@ -316,7 +316,7 @@ pub fn local_player_ai_step( abilities, swimming, sleeping_pos, - instance_holder, + world_holder, position, hunger, last_sent_input, @@ -333,7 +333,7 @@ pub fn local_player_ai_step( let is_passenger = false; let is_sleeping = sleeping_pos.is_some(); - let world = instance_holder.instance.read(); + let world = world_holder.shared.read(); let ctx = CanPlayerFitCtx { world: &world, entity, @@ -587,16 +587,16 @@ pub fn update_pose( &Physics, &PhysicsState, &LocalGameMode, - &InstanceHolder, + &WorldHolder, &Position, )>, aabb_query: AabbQuery, collidable_entity_query: CollidableEntityQuery, ) { - for (entity, mut pose, physics, physics_state, game_mode, instance_holder, position) in + for (entity, mut pose, physics, physics_state, game_mode, world_holder, position) in query.iter_mut() { - let world = instance_holder.instance.read(); + let world = world_holder.shared.read(); let world = &*world; let ctx = CanPlayerFitCtx { world, @@ -642,7 +642,7 @@ pub fn update_pose( } struct CanPlayerFitCtx<'world, 'state, 'a, 'b> { - world: &'a Instance, + world: &'a World, entity: Entity, position: Position, aabb_query: &'a AabbQuery<'world, 'state, 'b>, |
