diff options
| author | mat <git@matdoes.dev> | 2025-02-01 20:35:57 +0000 |
|---|---|---|
| committer | mat <git@matdoes.dev> | 2025-02-01 20:35:57 +0000 |
| commit | 87c34e1c3355e2b950f3c6f4ae44dcdfb775bbca (patch) | |
| tree | f725697c27f1959a97d48d5ed6e4a25266dcdd6b /azalea/src/pathfinder/simulation.rs | |
| parent | 4aa5010ea2dec8633be29b0a06c9b2233d7a6522 (diff) | |
| download | azalea-drasl-87c34e1c3355e2b950f3c6f4ae44dcdfb775bbca.tar.xz | |
add failing test_set_health_before_login test
Diffstat (limited to 'azalea/src/pathfinder/simulation.rs')
| -rw-r--r-- | azalea/src/pathfinder/simulation.rs | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/azalea/src/pathfinder/simulation.rs b/azalea/src/pathfinder/simulation.rs index 1f29ad24..0067c19f 100644 --- a/azalea/src/pathfinder/simulation.rs +++ b/azalea/src/pathfinder/simulation.rs @@ -7,6 +7,7 @@ use azalea_core::{position::Vec3, resource_location::ResourceLocation, tick::Gam use azalea_entity::{ attributes::AttributeInstance, Attributes, EntityDimensions, LookDirection, Physics, Position, }; +use azalea_registry::EntityKind; use azalea_world::{ChunkStorage, Instance, InstanceContainer, MinecraftEntityId, PartialInstance}; use bevy_app::App; use bevy_ecs::prelude::*; @@ -25,16 +26,13 @@ pub struct SimulatedPlayerBundle { impl SimulatedPlayerBundle { pub fn new(position: Vec3) -> Self { - let dimensions = EntityDimensions { - width: 0.6, - height: 1.8, - }; + let dimensions = EntityDimensions::from(EntityKind::Player); SimulatedPlayerBundle { position: Position::new(position), physics: Physics::new(dimensions, position), physics_state: PhysicsState::default(), - look_direction: LookDirection::new(0.0, 0.0), + look_direction: LookDirection::default(), attributes: Attributes { speed: AttributeInstance::new(0.1), attack_speed: AttributeInstance::new(4.0), |
