pub struct BlockDisplayEntity {
base: EntityBase,
entity_type: EntityTypeRef,
entity_data: SyncMutex<BlockDisplayEntityData>,
}Expand description
A block display entity that renders a block state at its position.
Block displays are purely visual entities with no collision. They support transformation (translation, rotation, scale) and interpolation for smooth animations.
Fields§
§base: EntityBaseCommon entity fields (id, uuid, position, etc.).
entity_type: EntityTypeRefVanilla entity type registered for this implementation.
entity_data: SyncMutex<BlockDisplayEntityData>Synced entity data for network serialization.
Implementations§
Source§impl BlockDisplayEntity
impl BlockDisplayEntity
Sourcepub fn new(
entity_type: EntityTypeRef,
id: i32,
position: DVec3,
world: Weak<World>,
) -> Self
pub fn new( entity_type: EntityTypeRef, id: i32, position: DVec3, world: Weak<World>, ) -> Self
Creates a new block display entity.
The id should be obtained from next_entity_id().
Sourcepub fn with_uuid(
entity_type: EntityTypeRef,
id: i32,
position: DVec3,
uuid: Uuid,
world: Weak<World>,
) -> Self
pub fn with_uuid( entity_type: EntityTypeRef, id: i32, position: DVec3, uuid: Uuid, world: Weak<World>, ) -> Self
Creates a new block display entity with a specific UUID.
The id should be obtained from next_entity_id().
Sourcepub fn from_saved(entity_type: EntityTypeRef, load: EntityBaseLoad) -> Self
pub fn from_saved(entity_type: EntityTypeRef, load: EntityBaseLoad) -> Self
Creates a block display entity from saved data.
Display entities have no physical collision, but vanilla base state is still persisted and should round-trip through the shared base.
Sourcepub const fn entity_data(&self) -> &SyncMutex<BlockDisplayEntityData>
pub const fn entity_data(&self) -> &SyncMutex<BlockDisplayEntityData>
Gets a reference to the entity data for reading/modifying synced state.
Sourcepub fn set_block_state_id(&self, id: BlockStateId)
pub fn set_block_state_id(&self, id: BlockStateId)
Sets the block state ID of this entity.
Trait Implementations§
Source§impl DowncastType for BlockDisplayEntity
impl DowncastType for BlockDisplayEntity
Source§const TYPE_KEY: DowncastTypeKey
const TYPE_KEY: DowncastTypeKey
Source§impl Entity for BlockDisplayEntity
impl Entity for BlockDisplayEntity
Source§fn base(&self) -> &EntityBase
fn base(&self) -> &EntityBase
Source§fn entity_type(&self) -> EntityTypeRef
fn entity_type(&self) -> EntityTypeRef
Source§fn synced_data(&self) -> Option<&dyn EntitySyncedData>
fn synced_data(&self) -> Option<&dyn EntitySyncedData>
Source§fn is_ignoring_block_triggers(&self) -> bool
fn is_ignoring_block_triggers(&self) -> bool
Source§fn save_additional(&self, nbt: &mut NbtCompound)
fn save_additional(&self, nbt: &mut NbtCompound)
Source§fn load_additional(&self, nbt: BorrowedNbtCompoundView<'_, '_>)
fn load_additional(&self, nbt: BorrowedNbtCompoundView<'_, '_>)
Source§fn is_always_ticking(&self) -> bool
fn is_always_ticking(&self) -> bool
Source§fn broadcast_to_player(&self, _player: &Player) -> bool
fn broadcast_to_player(&self, _player: &Player) -> bool
Source§fn generation(&self) -> EntityGeneration
fn generation(&self) -> EntityGeneration
Source§fn scoreboard_name(&self) -> String
fn scoreboard_name(&self) -> String
Source§fn name(&self) -> TextComponent
fn name(&self) -> TextComponent
Source§fn display_name(&self) -> TextComponent
fn display_name(&self) -> TextComponent
Source§fn plain_text_name(&self) -> String
fn plain_text_name(&self) -> String
Source§fn nbt_for_data_compare(&self) -> NbtCompound
fn nbt_for_data_compare(&self) -> NbtCompound
Source§fn nbt_for_passenger_save(&self) -> Option<NbtCompound>
fn nbt_for_passenger_save(&self) -> Option<NbtCompound>
Source§fn spawn_position(&self) -> DVec3
fn spawn_position(&self) -> DVec3
Source§fn block_position(&self) -> BlockPos
fn block_position(&self) -> BlockPos
Source§fn in_block_state(&self, world: &World) -> BlockStateId
fn in_block_state(&self, world: &World) -> BlockStateId
Source§fn old_position(&self) -> DVec3
fn old_position(&self) -> DVec3
Source§fn bounding_box(&self) -> WorldAabb
fn bounding_box(&self) -> WorldAabb
Source§fn is_free(&self, delta: DVec3) -> bool
fn is_free(&self, delta: DVec3) -> bool
delta is free of block
collisions and liquids.Source§fn blocks_building(&self) -> bool
fn blocks_building(&self) -> bool
Source§fn is_pickable(&self) -> bool
fn is_pickable(&self) -> bool
Source§fn attackable(&self) -> bool
fn attackable(&self) -> bool
Source§fn skip_attack_interaction(&self, _source: &SharedEntity) -> bool
fn skip_attack_interaction(&self, _source: &SharedEntity) -> bool
Source§fn is_pushable(&self) -> bool
fn is_pushable(&self) -> bool
Source§fn is_pushed_by_fluid(&self) -> bool
fn is_pushed_by_fluid(&self) -> bool
Source§fn on_above_bubble_column(&self, drag_down: bool, pos: BlockPos)
fn on_above_bubble_column(&self, drag_down: bool, pos: BlockPos)
Source§fn default_on_above_bubble_column(&self, drag_down: bool, pos: BlockPos)
fn default_on_above_bubble_column(&self, drag_down: bool, pos: BlockPos)
Source§fn on_inside_bubble_column(&self, drag_down: bool)
fn on_inside_bubble_column(&self, drag_down: bool)
Source§fn default_on_inside_bubble_column(&self, drag_down: bool)
fn default_on_inside_bubble_column(&self, drag_down: bool)
Source§fn is_spectator(&self) -> bool
fn is_spectator(&self) -> bool
Source§fn explosion_indirect_source(&self) -> Option<SharedEntity>
fn explosion_indirect_source(&self) -> Option<SharedEntity>
Source§fn explosion_damage_origin(&self) -> DVec3
fn explosion_damage_origin(&self) -> DVec3
Source§fn ignore_explosion(&self, _explosion: &dyn Explosion) -> bool
fn ignore_explosion(&self, _explosion: &dyn Explosion) -> bool
Source§fn block_explosion_resistance(
&self,
explosion: &dyn Explosion,
world: &World,
pos: BlockPos,
state: BlockStateId,
fluid: FluidState,
resistance: f32,
) -> f32
fn block_explosion_resistance( &self, explosion: &dyn Explosion, world: &World, pos: BlockPos, state: BlockStateId, fluid: FluidState, resistance: f32, ) -> f32
Source§fn should_block_explode(
&self,
explosion: &dyn Explosion,
world: &World,
pos: BlockPos,
state: BlockStateId,
power: f32,
) -> bool
fn should_block_explode( &self, explosion: &dyn Explosion, world: &World, pos: BlockPos, state: BlockStateId, power: f32, ) -> bool
Source§fn on_explosion_hit(&self, _explosion_source: Option<&dyn Entity>)
fn on_explosion_hit(&self, _explosion_source: Option<&dyn Entity>)
Source§fn piston_push_reaction(&self) -> PushReaction
fn piston_push_reaction(&self) -> PushReaction
Source§fn is_supported_by(&self, pos: BlockPos) -> bool
fn is_supported_by(&self, pos: BlockPos) -> bool
pos.Source§fn can_interact_with_level(&self) -> bool
fn can_interact_with_level(&self) -> bool
Source§fn is_invisible(&self) -> bool
fn is_invisible(&self) -> bool
Source§fn is_discrete(&self) -> bool
fn is_discrete(&self) -> bool
Source§fn is_allied_to(&self, _other: &dyn Entity) -> bool
fn is_allied_to(&self, _other: &dyn Entity) -> bool
other.Source§fn is_marker_armor_stand(&self) -> bool
fn is_marker_armor_stand(&self) -> bool
Source§fn is_tame_owned_by(&self, _owner: &dyn LivingEntity) -> bool
fn is_tame_owned_by(&self, _owner: &dyn LivingEntity) -> bool
owner.Source§fn projectile_owner_uuid(&self) -> Option<Uuid>
fn projectile_owner_uuid(&self) -> Option<Uuid>
Projectile owner UUID when this entity exposes one.Source§fn projectile_owner(&self) -> Option<SharedEntity>
fn projectile_owner(&self) -> Option<SharedEntity>
Projectile owner when this entity exposes one.Source§fn is_flying_player(&self) -> bool
fn is_flying_player(&self) -> bool
flying set.Source§fn can_be_collided_with(&self, _other: Option<&dyn Entity>) -> bool
fn can_be_collided_with(&self, _other: Option<&dyn Entity>) -> bool
other can collide with this entity. Read moreSource§fn is_hard_collision_relevant(&self) -> bool
fn is_hard_collision_relevant(&self) -> bool
Source§fn can_be_hit_by_projectile(&self) -> bool
fn can_be_hit_by_projectile(&self) -> bool
Source§fn deflection(&self, _projectile: &dyn Projectile) -> ProjectileDeflection
fn deflection(&self, _projectile: &dyn Projectile) -> ProjectileDeflection
Source§fn vehicle(&self) -> Option<SharedEntity>
fn vehicle(&self) -> Option<SharedEntity>
Source§fn controlled_vehicle(&self) -> Option<SharedEntity>
fn controlled_vehicle(&self) -> Option<SharedEntity>
Source§fn is_passenger(&self) -> bool
fn is_passenger(&self) -> bool
Source§fn can_ride(&self, _vehicle: &dyn Entity) -> bool
fn can_ride(&self, _vehicle: &dyn Entity) -> bool
vehicle.Source§fn stop_riding(&self)
fn stop_riding(&self)
Source§fn eject_passengers(&self)
fn eject_passengers(&self)
Source§fn start_riding(&self, entity_to_ride: &SharedEntity) -> bool
fn start_riding(&self, entity_to_ride: &SharedEntity) -> bool
entity_to_ride if vanilla boarding rules allow it.Source§fn passengers(&self) -> Vec<SharedEntity> ⓘ
fn passengers(&self) -> Vec<SharedEntity> ⓘ
Source§fn count_player_passengers(&self) -> usize
fn count_player_passengers(&self) -> usize
Source§fn has_exactly_one_player_passenger(&self) -> bool
fn has_exactly_one_player_passenger(&self) -> bool
Source§fn first_passenger(&self) -> Option<SharedEntity>
fn first_passenger(&self) -> Option<SharedEntity>
Source§fn controlling_passenger(&self) -> Option<SharedEntity>
fn controlling_passenger(&self) -> Option<SharedEntity>
Source§fn can_control_vehicle(&self) -> bool
fn can_control_vehicle(&self) -> bool
Source§fn has_controlling_passenger(&self) -> bool
fn has_controlling_passenger(&self) -> bool
Source§fn is_vehicle(&self) -> bool
fn is_vehicle(&self) -> bool
Source§fn dismounts_underwater(&self) -> bool
fn dismounts_underwater(&self) -> bool
dismounts_underwater entity type tag.Source§fn has_passenger(&self, passenger: &dyn Entity) -> bool
fn has_passenger(&self, passenger: &dyn Entity) -> bool
passenger is a direct passenger of this entity.Source§fn can_add_passenger(&self, _passenger: &dyn Entity) -> bool
fn can_add_passenger(&self, _passenger: &dyn Entity) -> bool
passenger as a direct passenger.Source§fn could_accept_passenger(&self) -> bool
fn could_accept_passenger(&self) -> bool
Source§fn passenger_index(&self, passenger: &dyn Entity) -> Option<usize>
fn passenger_index(&self, passenger: &dyn Entity) -> Option<usize>
Source§fn vehicle_attachment_point(&self, _vehicle: &dyn Entity) -> DVec3
fn vehicle_attachment_point(&self, _vehicle: &dyn Entity) -> DVec3
Source§fn default_passenger_attachment_point(&self, passenger: &dyn Entity) -> DVec3
fn default_passenger_attachment_point(&self, passenger: &dyn Entity) -> DVec3
Source§fn passenger_attachment_point(&self, passenger: &dyn Entity) -> DVec3
fn passenger_attachment_point(&self, passenger: &dyn Entity) -> DVec3
Source§fn passenger_riding_position(&self, passenger: &dyn Entity) -> DVec3
fn passenger_riding_position(&self, passenger: &dyn Entity) -> DVec3
passenger should ride this vehicle.Source§fn position_rider(&self, passenger: &dyn Entity)
fn position_rider(&self, passenger: &dyn Entity)
Source§fn root_vehicle_id(&self) -> i32
fn root_vehicle_id(&self) -> i32
Source§fn root_vehicle(&self) -> Option<SharedEntity>
fn root_vehicle(&self) -> Option<SharedEntity>
Source§fn is_passenger_of_same_vehicle(&self, other: &dyn Entity) -> bool
fn is_passenger_of_same_vehicle(&self, other: &dyn Entity) -> bool
other share the same root vehicle.Source§fn has_indirect_passenger(&self, entity: &dyn Entity) -> bool
fn has_indirect_passenger(&self, entity: &dyn Entity) -> bool
entity is an indirect passenger of this entity.Source§fn can_collide_with(&self, other: &dyn Entity) -> bool
fn can_collide_with(&self, other: &dyn Entity) -> bool
other.Source§fn as_default_entity_push(&self) -> Option<&dyn DefaultEntityPush>
fn as_default_entity_push(&self) -> Option<&dyn DefaultEntityPush>
DefaultEntityPush fast path. It is read under the
entity manager lock, so it must give the same answer for the entity’s whole
lifetime and have no side effects.Source§fn push_impulse(&self, impulse: DVec3)
fn push_impulse(&self, impulse: DVec3)
Source§fn push_entity(&self, entity: &dyn Entity)
fn push_entity(&self, entity: &dyn Entity)
Source§fn make_bounding_box_at(&self, position: DVec3) -> WorldAabb
fn make_bounding_box_at(&self, position: DVec3) -> WorldAabb
position.Source§fn get_relative_portal_position(
&self,
axis: Axis,
portal_area: FoundRectangle,
) -> DVec3
fn get_relative_portal_position( &self, axis: Axis, portal_area: FoundRectangle, ) -> DVec3
Source§fn default_tick(&self)
fn default_tick(&self)
super.tick() should call this
rather than calling Self::base_tick directly.Source§fn tick(self: Arc<Self>)
fn tick(self: Arc<Self>)
Source§fn ride_tick(self: Arc<Self>)
fn ride_tick(self: Arc<Self>)
Source§fn default_ride_tick(self: Arc<Self>)
fn default_ride_tick(self: Arc<Self>)
Entity.rideTick when not overridden.Source§fn handle_portal(&self)
fn handle_portal(&self)
Entity.handlePortal behavior currently implemented by Steel.Source§fn entity_base_tick(&self)
fn entity_base_tick(&self)
Entity.baseTick behavior. Read moreSource§fn check_below_world(&self)
fn check_below_world(&self)
Source§fn on_below_world(&self)
fn on_below_world(&self)
Source§fn check_despawn(&self)
fn check_despawn(&self)
Source§fn apply_inside_block_effect(&self, effect_type: InsideBlockEffectType)
fn apply_inside_block_effect(&self, effect_type: InsideBlockEffectType)
Source§fn pack_dirty_entity_data(&self) -> Option<Vec<DataValue>>
fn pack_dirty_entity_data(&self) -> Option<Vec<DataValue>>
Source§fn pack_all_entity_data(&self) -> Vec<DataValue>
fn pack_all_entity_data(&self) -> Vec<DataValue>
Source§fn update_data_before_sync(&self)
fn update_data_before_sync(&self)
Source§fn is_removed(&self) -> bool
fn is_removed(&self) -> bool
Source§fn is_alive(&self) -> bool
fn is_alive(&self) -> bool
Source§fn begin_pending_world_change(&self) -> Option<PendingWorldChangeToken>
fn begin_pending_world_change(&self) -> Option<PendingWorldChangeToken>
Source§fn finish_pending_world_change(&self, token: PendingWorldChangeToken) -> bool
fn finish_pending_world_change(&self, token: PendingWorldChangeToken) -> bool
Source§fn is_world_change_pending(&self) -> bool
fn is_world_change_pending(&self) -> bool
Source§fn is_world_change_token_pending(&self, token: PendingWorldChangeToken) -> bool
fn is_world_change_token_pending(&self, token: PendingWorldChangeToken) -> bool
Source§fn can_use_portal(&self, ignore_passenger: bool) -> bool
fn can_use_portal(&self, ignore_passenger: bool) -> bool
Source§fn dimension_changing_delay(&self) -> i32
fn dimension_changing_delay(&self) -> i32
Source§fn removal_reason(&self) -> Option<RemovalReason>
fn removal_reason(&self) -> Option<RemovalReason>
Source§fn set_removed(&self, reason: RemovalReason)
fn set_removed(&self, reason: RemovalReason)
Source§fn game_event_with_source_entity(
&self,
event: GameEventRef,
source_entity: Option<&dyn Entity>,
)
fn game_event_with_source_entity( &self, event: GameEventRef, source_entity: Option<&dyn Entity>, )
Source§fn game_event(&self, event: GameEventRef)
fn game_event(&self, event: GameEventRef)
Source§fn kill(&self, world: &World)
fn kill(&self, world: &World)
Source§fn restore_owner_reference(&self, _owner: &SharedEntity)
fn restore_owner_reference(&self, _owner: &SharedEntity)
Source§fn on_teleported(&self)
fn on_teleported(&self)
Source§fn set_level_callback(&self, callback: Arc<dyn EntityLevelCallback>)
fn set_level_callback(&self, callback: Arc<dyn EntityLevelCallback>)
Source§fn notify_leash_holder(&self, _leashable: &dyn Entity)
fn notify_leash_holder(&self, _leashable: &dyn Entity)
Source§fn notify_leashee_removed(&self, _leashable: &dyn Entity)
fn notify_leashee_removed(&self, _leashable: &dyn Entity)
Source§fn player_touch(self: Arc<Self>, _player: &Arc<Player>)
fn player_touch(self: Arc<Self>, _player: &Arc<Player>)
Source§fn leashables_leashed_to(&self) -> Vec<SharedEntity> ⓘ
fn leashables_leashed_to(&self) -> Vec<SharedEntity> ⓘ
Source§fn leashables_leashed_to_holder_in_area(
&self,
holder: &dyn Entity,
) -> Vec<SharedEntity> ⓘ
fn leashables_leashed_to_holder_in_area( &self, holder: &dyn Entity, ) -> Vec<SharedEntity> ⓘ
holder.Source§fn transfer_leashables_from_holder(&self, old_holder: &dyn Entity) -> bool
fn transfer_leashables_from_holder(&self, old_holder: &dyn Entity) -> bool
old_holder to this entity.Source§fn drop_all_leash_connections(&self, player: Option<&Player>) -> bool
fn drop_all_leash_connections(&self, player: Option<&Player>) -> bool
Source§fn shear_off_all_leash_connections(&self, player: Option<&Player>) -> bool
fn shear_off_all_leash_connections(&self, player: Option<&Player>) -> bool
Source§fn attempt_to_shear_equipment(
&self,
player: &Player,
hand: InteractionHand,
) -> bool
fn attempt_to_shear_equipment( &self, player: &Player, hand: InteractionHand, ) -> bool
Source§fn interact(
&self,
player: &Player,
hand: InteractionHand,
location: DVec3,
) -> InteractionResult
fn interact( &self, player: &Player, hand: InteractionHand, location: DVec3, ) -> InteractionResult
Source§fn interact_entity(
&self,
player: &Player,
hand: InteractionHand,
_location: DVec3,
) -> InteractionResult
fn interact_entity( &self, player: &Player, hand: InteractionHand, _location: DVec3, ) -> InteractionResult
Source§fn is_living_entity(&self) -> bool
fn is_living_entity(&self) -> bool
Source§fn is_abstract_arrow(&self) -> bool
fn is_abstract_arrow(&self) -> bool
AbstractArrow hierarchy.Source§fn as_projectile(&self) -> Option<&dyn Projectile>
fn as_projectile(&self) -> Option<&dyn Projectile>
Source§fn as_living_entity(&self) -> Option<&dyn LivingEntity>
fn as_living_entity(&self) -> Option<&dyn LivingEntity>
Source§fn as_item_frame(&self) -> Option<&dyn ItemFrame>
fn as_item_frame(&self) -> Option<&dyn ItemFrame>
Source§fn as_player(&self) -> Option<&Player>
fn as_player(&self) -> Option<&Player>
Source§fn with_weapon_item(&self, visitor: &mut dyn FnMut(Option<&ItemStack>))
fn with_weapon_item(&self, visitor: &mut dyn FnMut(Option<&ItemStack>))
Entity.getWeaponItem without copying inventory state.Source§fn is_pathfinder_mob(&self) -> bool
fn is_pathfinder_mob(&self) -> bool
Source§fn as_pathfinder_mob(&self) -> Option<&dyn PathfinderMob>
fn as_pathfinder_mob(&self) -> Option<&dyn PathfinderMob>
Source§fn as_leashable(&self) -> Option<&dyn Leashable>
fn as_leashable(&self) -> Option<&dyn Leashable>
Leashable if it has Leashable behavior.Source§fn as_abstract_minecart(&self) -> Option<&dyn AbstractMinecart>
fn as_abstract_minecart(&self) -> Option<&dyn AbstractMinecart>
AbstractMinecart if it has AbstractMinecart behavior.Source§fn as_animal(&self) -> Option<&dyn Animal>
fn as_animal(&self) -> Option<&dyn Animal>
Source§fn is_monster(&self) -> bool
fn is_monster(&self) -> bool
Source§fn as_monster(&self) -> Option<&dyn Monster>
fn as_monster(&self) -> Option<&dyn Monster>
Monster capability, equivalent to vanilla’s instanceof Monster.Source§fn as_enemy(&self) -> Option<&dyn Enemy>
fn as_enemy(&self) -> Option<&dyn Enemy>
Enemy marker, equivalent to vanilla’s instanceof Enemy.Source§fn is_ageable_mob(&self) -> bool
fn is_ageable_mob(&self) -> bool
Source§fn as_ageable_mob(&self) -> Option<&dyn AgeableMob>
fn as_ageable_mob(&self) -> Option<&dyn AgeableMob>
Source§fn is_item_steerable(&self) -> bool
fn is_item_steerable(&self) -> bool
Source§fn as_item_steerable(&self) -> Option<&dyn ItemSteerable>
fn as_item_steerable(&self) -> Option<&dyn ItemSteerable>
Source§fn forces_fall_flying_velocity_sync(&self) -> bool
fn forces_fall_flying_velocity_sync(&self) -> bool
Source§fn uses_client_movement_packets(&self) -> bool
fn uses_client_movement_packets(&self) -> bool
Source§fn is_server_driven_movement(&self) -> bool
fn is_server_driven_movement(&self) -> bool
Source§fn can_simulate_movement(&self) -> bool
fn can_simulate_movement(&self) -> bool
Source§fn is_effective_ai(&self) -> bool
fn is_effective_ai(&self) -> bool
Source§fn is_suppressing_bounce(&self) -> bool
fn is_suppressing_bounce(&self) -> bool
Source§fn is_stepping_carefully(&self) -> bool
fn is_stepping_carefully(&self) -> bool
Source§fn is_descending(&self) -> bool
fn is_descending(&self) -> bool
Source§fn update_swimming(&self)
fn update_swimming(&self)
Source§fn default_update_swimming(&self)
fn default_update_swimming(&self)
Entity.updateSwimming for player overrides.Source§fn is_flying_vehicle(&self) -> bool
fn is_flying_vehicle(&self) -> bool
Source§fn on_climbable(&self) -> bool
fn on_climbable(&self) -> bool
Source§fn default_known_movement(&self) -> DVec3
fn default_known_movement(&self) -> DVec3
Source§fn known_movement(&self) -> DVec3
fn known_movement(&self) -> DVec3
Source§fn known_speed(&self) -> DVec3
fn known_speed(&self) -> DVec3
getKnownSpeed.Source§fn tick_count(&self) -> i32
fn tick_count(&self) -> i32
Source§fn is_first_tick(&self) -> bool
fn is_first_tick(&self) -> bool
Source§fn set_first_tick(&self, first_tick: bool)
fn set_first_tick(&self, first_tick: bool)
Source§fn advance_tick_count(&self)
fn advance_tick_count(&self)
Source§fn fall_sounds(&self) -> (SoundEventRef, SoundEventRef)
fn fall_sounds(&self) -> (SoundEventRef, SoundEventRef)
Source§fn rotation(&self) -> (f32, f32)
fn rotation(&self) -> (f32, f32)
Source§fn set_rotation(&self, rotation: (f32, f32))
fn set_rotation(&self, rotation: (f32, f32))
Source§fn direction_yaw(&self) -> Direction
fn direction_yaw(&self) -> Direction
Source§fn motion_direction(&self) -> Direction
fn motion_direction(&self) -> Direction
Source§fn look_at(&self, from_anchor: EntityAnchor, target: DVec3)
fn look_at(&self, from_anchor: EntityAnchor, target: DVec3)
Source§fn look_at_entity(
&self,
from_anchor: EntityAnchor,
target: &dyn Entity,
target_anchor: EntityAnchor,
)
fn look_at_entity( &self, from_anchor: EntityAnchor, target: &dyn Entity, target_anchor: EntityAnchor, )
Source§fn spawn_data(&self) -> i32
fn spawn_data(&self) -> i32
Source§fn get_eye_height(&self) -> f64
fn get_eye_height(&self) -> f64
Source§fn get_fluid_jump_threshold(&self) -> f64
fn get_fluid_jump_threshold(&self) -> f64
Source§fn is_in_wall(&self) -> bool
fn is_in_wall(&self) -> bool
Source§fn calculate_view_vector(&self, pitch_degrees: f32, yaw_degrees: f32) -> DVec3
fn calculate_view_vector(&self, pitch_degrees: f32, yaw_degrees: f32) -> DVec3
Source§fn look_angle(&self) -> DVec3
fn look_angle(&self) -> DVec3
Source§fn hand_holding_item_angle(&self, item: ItemRef) -> DVec3
fn hand_holding_item_angle(&self, item: ItemRef) -> DVec3
item. Read moreSource§fn set_velocity(&self, velocity: DVec3)
fn set_velocity(&self, velocity: DVec3)
Source§fn needs_velocity_sync(&self) -> bool
fn needs_velocity_sync(&self) -> bool
Source§fn mark_velocity_sync(&self)
fn mark_velocity_sync(&self)
Source§fn clear_velocity_sync(&self)
fn clear_velocity_sync(&self)
Source§fn hurt_marked(&self) -> bool
fn hurt_marked(&self) -> bool
Source§fn clear_hurt_mark(&self)
fn clear_hurt_mark(&self)
Source§fn fall_distance(&self) -> f64
fn fall_distance(&self) -> f64
Source§fn is_in_powder_snow(&self) -> bool
fn is_in_powder_snow(&self) -> bool
Source§fn was_in_powder_snow(&self) -> bool
fn was_in_powder_snow(&self) -> bool
Source§fn set_fall_distance(&self, fall_distance: f64)
fn set_fall_distance(&self, fall_distance: f64)
Source§fn reset_fall_distance(&self)
fn reset_fall_distance(&self)
Source§fn check_fall_distance_accumulation(&self)
fn check_fall_distance_accumulation(&self)
Source§fn fire_freeze_state(&self) -> EntityFireFreezeState
fn fire_freeze_state(&self) -> EntityFireFreezeState
Source§fn remaining_fire_ticks(&self) -> i32
fn remaining_fire_ticks(&self) -> i32
Source§fn set_remaining_fire_ticks(&self, remaining_fire_ticks: i32)
fn set_remaining_fire_ticks(&self, remaining_fire_ticks: i32)
Source§fn ticks_frozen(&self) -> i32
fn ticks_frozen(&self) -> i32
Source§fn set_ticks_frozen(&self, ticks_frozen: i32)
fn set_ticks_frozen(&self, ticks_frozen: i32)
Source§fn fire_immune(&self) -> bool
fn fire_immune(&self) -> bool
Source§fn fire_immune_ticks(&self) -> i32
fn fire_immune_ticks(&self) -> i32
Source§fn should_play_lava_hurt_sound(&self) -> bool
fn should_play_lava_hurt_sound(&self) -> bool
Source§fn lava_ignite(&self)
fn lava_ignite(&self)
Source§fn remaining_fire_ticks_cap(&self) -> Option<i32>
fn remaining_fire_ticks_cap(&self) -> Option<i32>
None means unlimited.Source§fn fire_ignite_extra_ticks(&self) -> i32
fn fire_ignite_extra_ticks(&self) -> i32
Source§fn is_on_fire(&self) -> bool
fn is_on_fire(&self) -> bool
Source§fn has_visual_fire(&self) -> bool
fn has_visual_fire(&self) -> bool
Source§fn is_freezing(&self) -> bool
fn is_freezing(&self) -> bool
Source§fn default_can_freeze(&self) -> bool
fn default_can_freeze(&self) -> bool
Entity.canFreeze() without living-equipment overrides.Source§fn can_freeze(&self) -> bool
fn can_freeze(&self) -> bool
Source§fn ticks_required_to_freeze(&self) -> i32
fn ticks_required_to_freeze(&self) -> i32
Source§fn is_fully_frozen(&self) -> bool
fn is_fully_frozen(&self) -> bool
Source§fn percent_frozen(&self) -> f32
fn percent_frozen(&self) -> f32
Source§fn clear_freeze(&self)
fn clear_freeze(&self)
Source§fn clear_fire(&self)
fn clear_fire(&self)
Source§fn extinguish_fire(&self)
fn extinguish_fire(&self)
Source§fn ignite_for_ticks(&self, number_of_ticks: i32)
fn ignite_for_ticks(&self, number_of_ticks: i32)
Source§fn sync_base_fire_freeze_entity_data(&self)
fn sync_base_fire_freeze_entity_data(&self)
Source§fn sync_base_entity_data(&self)
fn sync_base_entity_data(&self)
Source§fn is_in_water(&self) -> bool
fn is_in_water(&self) -> bool
Source§fn is_in_rain(&self) -> bool
fn is_in_rain(&self) -> bool
Source§fn is_in_water_or_rain(&self) -> bool
fn is_in_water_or_rain(&self) -> bool
Source§fn is_in_lava(&self) -> bool
fn is_in_lava(&self) -> bool
Source§fn is_eye_in_water(&self) -> bool
fn is_eye_in_water(&self) -> bool
Source§fn is_eye_in_lava(&self) -> bool
fn is_eye_in_lava(&self) -> bool
Source§fn is_under_water(&self) -> bool
fn is_under_water(&self) -> bool
Source§fn fluid_contact(&self) -> EntityFluidContact
fn fluid_contact(&self) -> EntityFluidContact
Source§fn refresh_fluid_contact(&self) -> EntityFluidContact
fn refresh_fluid_contact(&self) -> EntityFluidContact
Source§fn update_fluid_interaction(&self) -> bool
fn update_fluid_interaction(&self) -> bool
Entity.updateFluidInteraction: refreshes cached contact,
emits the water-entry splash on transition, resets fall distance in
water, and applies fluid currents. Read moreSource§fn scan_and_store_fluid_contact(
&self,
advance_eye_water_history: bool,
) -> EntityFluidContact
fn scan_and_store_fluid_contact( &self, advance_eye_water_history: bool, ) -> EntityFluidContact
Source§fn apply_fluid_current_impulses(
&self,
world: &Arc<World>,
contact: EntityFluidContact,
)
fn apply_fluid_current_impulses( &self, world: &Arc<World>, contact: EntityFluidContact, )
Source§fn apply_fluid_current_impulse(&self, impulse: DVec3)
fn apply_fluid_current_impulse(&self, impulse: DVec3)
Source§fn is_fall_damage_immune(&self) -> bool
fn is_fall_damage_immune(&self) -> bool
Source§fn propagate_fall_to_passengers(
&self,
fall_distance: f64,
damage_modifier: f32,
source: &DamageSource,
)
fn propagate_fall_to_passengers( &self, fall_distance: f64, damage_modifier: f32, source: &DamageSource, )
Source§fn cause_fall_damage(
self: Arc<Self>,
fall_distance: f64,
damage_modifier: f32,
source: &DamageSource,
) -> bool
fn cause_fall_damage( self: Arc<Self>, fall_distance: f64, damage_modifier: f32, source: &DamageSource, ) -> bool
Source§fn horizontal_collision(&self) -> bool
fn horizontal_collision(&self) -> bool
Source§fn vertical_collision(&self) -> bool
fn vertical_collision(&self) -> bool
Source§fn vertical_collision_below(&self) -> bool
fn vertical_collision_below(&self) -> bool
Source§fn no_physics(&self) -> bool
fn no_physics(&self) -> bool
Source§fn is_affected_by_blocks(&self) -> bool
fn is_affected_by_blocks(&self) -> bool
Source§fn set_no_physics(&self, no_physics: bool)
fn set_no_physics(&self, no_physics: bool)
Source§fn update_no_physics_from_current_collision(&self)
fn update_no_physics_from_current_collision(&self)
noPhysics from the entity’s current collision state.Source§fn move_towards_closest_space(&self, x: f64, y: f64, z: f64)
fn move_towards_closest_space(&self, x: f64, y: f64, z: f64)
Source§fn default_make_stuck_in_block(
&self,
_state: BlockStateId,
speed_multiplier: DVec3,
)
fn default_make_stuck_in_block( &self, _state: BlockStateId, speed_multiplier: DVec3, )
Source§fn make_stuck_in_block(&self, state: BlockStateId, speed_multiplier: DVec3)
fn make_stuck_in_block(&self, state: BlockStateId, speed_multiplier: DVec3)
Source§fn apply_effects_from_blocks(&self)
fn apply_effects_from_blocks(&self)
Source§fn apply_effects_from_blocks_between(&self, from: DVec3, to: DVec3)
fn apply_effects_from_blocks_between(&self, from: DVec3, to: DVec3)
Source§fn apply_effects_from_blocks_for_last_movements(&self)
fn apply_effects_from_blocks_for_last_movements(&self)
Source§fn land_after_teleport(&self)
fn land_after_teleport(&self)
/teleport does once an entity has moved: unless it is gliding, it ends up
on the ground without vertical motion.Source§fn set_on_ground(&self, on_ground: bool)
fn set_on_ground(&self, on_ground: bool)
Source§fn set_on_ground_with_movement(
&self,
on_ground: bool,
horizontal_collision: bool,
movement: DVec3,
)
fn set_on_ground_with_movement( &self, on_ground: bool, horizontal_collision: bool, movement: DVec3, )
Source§fn default_apply_accepted_client_movement(
self: Arc<Self>,
world: &Arc<World>,
accepted: AcceptedClientMovement,
) -> Result<AcceptedClientMovementOutcome, EntityMoveError>
fn default_apply_accepted_client_movement( self: Arc<Self>, world: &Arc<World>, accepted: AcceptedClientMovement, ) -> Result<AcceptedClientMovementOutcome, EntityMoveError>
Source§fn apply_accepted_client_movement(
self: Arc<Self>,
world: &Arc<World>,
accepted: AcceptedClientMovement,
) -> Result<AcceptedClientMovementOutcome, EntityMoveError>
fn apply_accepted_client_movement( self: Arc<Self>, world: &Arc<World>, accepted: AcceptedClientMovement, ) -> Result<AcceptedClientMovementOutcome, EntityMoveError>
Source§fn apply_accepted_client_vehicle_movement(
self: Arc<Self>,
world: &Arc<World>,
accepted: AcceptedClientMovement,
) -> Result<AcceptedClientMovementOutcome, EntityMoveError>
fn apply_accepted_client_vehicle_movement( self: Arc<Self>, world: &Arc<World>, accepted: AcceptedClientMovement, ) -> Result<AcceptedClientMovementOutcome, EntityMoveError>
Source§fn try_set_position(&self, pos: DVec3) -> Result<(), EntityMoveError>
fn try_set_position(&self, pos: DVec3) -> Result<(), EntityMoveError>
Source§fn try_set_position_base(&self, pos: DVec3) -> Result<(), EntityMoveError>
fn try_set_position_base(&self, pos: DVec3) -> Result<(), EntityMoveError>
Source§fn teleport_to(&self, pos: DVec3) -> Result<(), EntityMoveError>
fn teleport_to(&self, pos: DVec3) -> Result<(), EntityMoveError>
pos, keeping its current rotation.Source§fn set_old_position_to_current(&self)
fn set_old_position_to_current(&self)
Source§fn set_old_position(&self, old_position: DVec3)
fn set_old_position(&self, old_position: DVec3)
Source§fn remove_latest_movement_recording(&self)
fn remove_latest_movement_recording(&self)
Source§fn on_pos(&self, offset: f32) -> Option<BlockPos>
fn on_pos(&self, offset: f32) -> Option<BlockPos>
Source§fn block_pos_below_that_affects_movement(&self) -> Option<BlockPos>
fn block_pos_below_that_affects_movement(&self) -> Option<BlockPos>
Source§fn on_pos_legacy(&self) -> Option<BlockPos>
fn on_pos_legacy(&self) -> Option<BlockPos>
getOnPosLegacy(), used by fall/step block hooks.Source§fn default_block_speed_factor(&self) -> f32
fn default_block_speed_factor(&self) -> f32
Source§fn block_speed_factor(&self) -> f32
fn block_speed_factor(&self) -> f32
Source§fn block_jump_factor(&self) -> f32
fn block_jump_factor(&self) -> f32
Source§fn pose(&self) -> EntityPose
fn pose(&self) -> EntityPose
Source§fn dimensions_for_pose(&self, _pose: EntityPose) -> EntityDimensions
fn dimensions_for_pose(&self, _pose: EntityPose) -> EntityDimensions
Source§fn refresh_dimensions(&self)
fn refresh_dimensions(&self)
Source§fn fudge_position_after_size_change(
&self,
previous_dimensions: EntityDimensions,
) -> bool
fn fudge_position_after_size_change( &self, previous_dimensions: EntityDimensions, ) -> bool
ThrownEgg hatchlings also use it to fit a newborn chick at the
egg’s impact point.Source§fn set_pose(&self, pose: EntityPose)
fn set_pose(&self, pose: EntityPose)
Source§fn is_crouching(&self) -> bool
fn is_crouching(&self) -> bool
Source§fn is_swimming(&self) -> bool
fn is_swimming(&self) -> bool
Source§fn is_on_rails(&self) -> bool
fn is_on_rails(&self) -> bool
Source§fn is_state_climbable(&self, state: BlockStateId) -> bool
fn is_state_climbable(&self, state: BlockStateId) -> bool
Source§fn movement_emission(&self) -> EntityMovementEmission
fn movement_emission(&self) -> EntityMovementEmission
Source§fn may_interact(&self, _world: &World, _pos: BlockPos) -> bool
fn may_interact(&self, _world: &World, _pos: BlockPos) -> bool
Source§fn air_supply(&self) -> i32
fn air_supply(&self) -> i32
Source§fn set_air_supply(&self, air_supply: i32)
fn set_air_supply(&self, air_supply: i32)
Source§fn max_air_supply(&self) -> i32
fn max_air_supply(&self) -> i32
Source§fn portal_cooldown(&self) -> i32
fn portal_cooldown(&self) -> i32
Source§fn set_portal_cooldown(&self, portal_cooldown: i32)
fn set_portal_cooldown(&self, portal_cooldown: i32)
Source§fn is_on_portal_cooldown(&self) -> bool
fn is_on_portal_cooldown(&self) -> bool
Source§fn reset_portal_cooldown(&self)
fn reset_portal_cooldown(&self)
Source§fn set_as_inside_portal(&self, portal: PortalKind, entry_position: BlockPos)
fn set_as_inside_portal(&self, portal: PortalKind, entry_position: BlockPos)
Source§fn custom_name(&self) -> Option<TextComponent>
fn custom_name(&self) -> Option<TextComponent>
Source§fn set_custom_name(&self, custom_name: Option<TextComponent>)
fn set_custom_name(&self, custom_name: Option<TextComponent>)
Source§fn is_custom_name_visible(&self) -> bool
fn is_custom_name_visible(&self) -> bool
Source§fn set_custom_name_visible(&self, visible: bool)
fn set_custom_name_visible(&self, visible: bool)
Source§fn has_glowing_tag(&self) -> bool
fn has_glowing_tag(&self) -> bool
Source§fn set_glowing_tag(&self, glowing: bool)
fn set_glowing_tag(&self, glowing: bool)
Source§fn remove_tag(&self, tag: &str) -> bool
fn remove_tag(&self, tag: &str) -> bool
Source§fn custom_data(&self) -> NbtCompound
fn custom_data(&self) -> NbtCompound
Source§fn set_custom_data(&self, custom_data: NbtCompound)
fn set_custom_data(&self, custom_data: NbtCompound)
Source§fn sound_source(&self) -> SoundSource
fn sound_source(&self) -> SoundSource
Source§fn swim_sound(&self) -> SoundEventRef
fn swim_sound(&self) -> SoundEventRef
Source§fn set_silent(&self, silent: bool)
fn set_silent(&self, silent: bool)
Source§fn broadcast_entity_event(&self, event: EntityStatus)
fn broadcast_entity_event(&self, event: EntityStatus)
Source§fn play_sound(&self, sound: SoundEventRef, volume: f32, pitch: f32)
fn play_sound(&self, sound: SoundEventRef, volume: f32, pitch: f32)
Source§fn swim_splash_sound(&self) -> SoundEventRef
fn swim_splash_sound(&self) -> SoundEventRef
Source§fn swim_high_speed_splash_sound(&self) -> SoundEventRef
fn swim_high_speed_splash_sound(&self) -> SoundEventRef
Source§fn do_water_splash_effect(&self)
fn do_water_splash_effect(&self)
SPLASH.Source§fn default_do_water_splash_effect(&self)
fn default_do_water_splash_effect(&self)
Entity.doWaterSplashEffect when not overridden.Source§fn play_entity_on_fire_extinguished_sound(&self)
fn play_entity_on_fire_extinguished_sound(&self)
Source§fn play_step_sound(&self, _pos: BlockPos, block_state: BlockStateId)
fn play_step_sound(&self, _pos: BlockPos, block_state: BlockStateId)
Source§fn play_block_step_sound(&self, block_state: BlockStateId)
fn play_block_step_sound(&self, block_state: BlockStateId)
Source§fn play_muffled_step_sound(&self, block_state: BlockStateId)
fn play_muffled_step_sound(&self, block_state: BlockStateId)
Source§fn play_combination_step_sounds(
&self,
primary_step_sound: BlockStateId,
secondary_step_sound: BlockStateId,
)
fn play_combination_step_sounds( &self, primary_step_sound: BlockStateId, secondary_step_sound: BlockStateId, )
Source§fn walking_step_sound(&self, pos: BlockPos, block_state: BlockStateId)
fn walking_step_sound(&self, pos: BlockPos, block_state: BlockStateId)
Source§fn play_amethyst_step_sound(&self)
fn play_amethyst_step_sound(&self)
Source§fn water_swim_sound(&self)
fn water_swim_sound(&self)
Source§fn play_swim_sound(&self, volume: f32)
fn play_swim_sound(&self, volume: f32)
Source§fn is_flapping(&self) -> bool
fn is_flapping(&self) -> bool
Source§fn process_flapping_movement(&self)
fn process_flapping_movement(&self)
Source§fn next_step(&self) -> f32
fn next_step(&self) -> f32
Source§fn apply_movement_emission_and_play_sound(
&self,
emission: EntityMovementEmission,
clipped_movement: DVec3,
effect_pos: BlockPos,
effect_state: BlockStateId,
)
fn apply_movement_emission_and_play_sound( &self, emission: EntityMovementEmission, clipped_movement: DVec3, effect_pos: BlockPos, effect_state: BlockStateId, )
Source§fn apply_movement_side_effects_after_move(
&self,
world: &World,
actual_movement: DVec3,
)
fn apply_movement_side_effects_after_move( &self, world: &World, actual_movement: DVec3, )
Source§fn vibration_and_sound_effects_from_block(
&self,
pos: BlockPos,
block_state: BlockStateId,
should_sound: bool,
should_vibrate: bool,
clipped_movement: DVec3,
) -> bool
fn vibration_and_sound_effects_from_block( &self, pos: BlockPos, block_state: BlockStateId, should_sound: bool, should_vibrate: bool, clipped_movement: DVec3, ) -> bool
Source§fn max_up_step(&self) -> f32
fn max_up_step(&self) -> f32
Source§fn backs_off_from_edge(&self) -> bool
fn backs_off_from_edge(&self) -> bool
Source§fn get_default_gravity(&self) -> f64
fn get_default_gravity(&self) -> f64
Source§fn is_no_gravity(&self) -> bool
fn is_no_gravity(&self) -> bool
Source§fn set_no_gravity(&self, no_gravity: bool)
fn set_no_gravity(&self, no_gravity: bool)
Source§fn is_invulnerable(&self) -> bool
fn is_invulnerable(&self) -> bool
Source§fn set_invulnerable(&self, invulnerable: bool)
fn set_invulnerable(&self, invulnerable: bool)
Source§fn get_gravity(&self) -> f64
fn get_gravity(&self) -> f64
Source§fn get_air_drag(&self) -> f64
fn get_air_drag(&self) -> f64
Source§fn apply_gravity(&self)
fn apply_gravity(&self)
Source§fn move_relative(&self, speed: f32, input: DVec3)
fn move_relative(&self, speed: f32, input: DVec3)
input scaled by speed, rotated to face this entity’s current
yaw, to its velocity.Source§fn move_without_physics(&self, delta: DVec3) -> Option<MoveResult>
fn move_without_physics(&self, delta: DVec3) -> Option<MoveResult>
Source§fn default_move_entity(
self: Arc<Self>,
mover_type: MoverType,
delta: DVec3,
) -> Option<MoveResult>
fn default_move_entity( self: Arc<Self>, mover_type: MoverType, delta: DVec3, ) -> Option<MoveResult>
Source§fn move_entity(
self: Arc<Self>,
mover_type: MoverType,
delta: DVec3,
) -> Option<MoveResult>
fn move_entity( self: Arc<Self>, mover_type: MoverType, delta: DVec3, ) -> Option<MoveResult>
Source§fn apply_fall_damage_after_move(
self: Arc<Self>,
result: &MoveResult,
world: &Arc<World>,
) -> bool
fn apply_fall_damage_after_move( self: Arc<Self>, result: &MoveResult, world: &Arc<World>, ) -> bool
Source§fn reset_fall_distance_on_resetting_clip(
&self,
world: &Arc<World>,
movement: DVec3,
)
fn reset_fall_distance_on_resetting_clip( &self, world: &Arc<World>, movement: DVec3, )
Source§fn do_check_fall_damage(
self: Arc<Self>,
movement: DVec3,
on_ground: bool,
world: &Arc<World>,
) -> bool
fn do_check_fall_damage( self: Arc<Self>, movement: DVec3, on_ground: bool, world: &Arc<World>, ) -> bool
Source§fn refresh_supporting_block_for_fall_damage(
&self,
movement: DVec3,
on_ground: bool,
)
fn refresh_supporting_block_for_fall_damage( &self, movement: DVec3, on_ground: bool, )
Source§fn send_landing_particles(
&self,
world: &World,
on_state: BlockStateId,
pos: BlockPos,
)
fn send_landing_particles( &self, world: &World, on_state: BlockStateId, pos: BlockPos, )
Source§fn check_fall_damage(
self: Arc<Self>,
vertical_movement: f64,
on_ground: bool,
on_state: BlockStateId,
pos: BlockPos,
world: &Arc<World>,
)
fn check_fall_damage( self: Arc<Self>, vertical_movement: f64, on_ground: bool, on_state: BlockStateId, pos: BlockPos, world: &Arc<World>, )
Source§fn ground_contact_after_movement(
&self,
on_ground: bool,
movement: Option<DVec3>,
) -> EntityGroundContact
fn ground_contact_after_movement( &self, on_ground: bool, movement: Option<DVec3>, ) -> EntityGroundContact
Source§fn check_supporting_block(
&self,
on_ground: bool,
movement: Option<DVec3>,
world: &Arc<World>,
) -> EntityGroundContact
fn check_supporting_block( &self, on_ground: bool, movement: Option<DVec3>, world: &Arc<World>, ) -> EntityGroundContact
Source§fn spawn_at_location(
&self,
item: ItemStack,
y_offset: f64,
) -> Option<Arc<ItemEntity>>
fn spawn_at_location( &self, item: ItemStack, y_offset: f64, ) -> Option<Arc<ItemEntity>>
Source§fn spawn_at_location_with_offset(
&self,
item: ItemStack,
offset: DVec3,
) -> Option<Arc<ItemEntity>>
fn spawn_at_location_with_offset( &self, item: ItemStack, offset: DVec3, ) -> Option<Arc<ItemEntity>>
Source§fn apply_implicit_item_components(&self, _item_stack: &ItemStack)
fn apply_implicit_item_components(&self, _item_stack: &ItemStack)
Source§fn apply_spawn_data(&self, nbt: BorrowedNbtCompoundView<'_, '_>)
fn apply_spawn_data(&self, nbt: BorrowedNbtCompoundView<'_, '_>)
Source§fn is_invulnerable_to_base(&self, source: &DamageSource) -> bool
fn is_invulnerable_to_base(&self, source: &DamageSource) -> bool
source: already
removed, or invulnerable and the source doesn’t bypass invulnerability.Source§fn hurt(&self, world: &World, source: &DamageSource, amount: f32) -> bool
fn hurt(&self, world: &World, source: &DamageSource, amount: f32) -> bool
Source§fn distance_to_sqr(&self, pos: DVec3) -> f64
fn distance_to_sqr(&self, pos: DVec3) -> f64
Source§fn snap_to(&self, position: DVec3, yaw: f32, pitch: f32)
fn snap_to(&self, position: DVec3, yaw: f32, pitch: f32)
Source§fn killed_entity(
&self,
_world: &World,
_entity: &dyn LivingEntity,
_source: &DamageSource,
) -> bool
fn killed_entity( &self, _world: &World, _entity: &dyn LivingEntity, _source: &DamageSource, ) -> bool
Source§fn award_kill_score(&self, _victim: &dyn Entity, _killing_blow: &DamageSource)
fn award_kill_score(&self, _victim: &dyn Entity, _killing_blow: &DamageSource)
Auto Trait Implementations§
impl !Freeze for BlockDisplayEntity
impl !RefUnwindSafe for BlockDisplayEntity
impl !UnwindSafe for BlockDisplayEntity
impl Send for BlockDisplayEntity
impl Sync for BlockDisplayEntity
impl Unpin for BlockDisplayEntity
impl UnsafeUnpin for BlockDisplayEntity
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Downcast for Twhere
T: ErasedType + ?Sized,
impl<T> Downcast for Twhere
T: ErasedType + ?Sized,
Source§fn is<T>(&self) -> boolwhere
T: DowncastType,
fn is<T>(&self) -> boolwhere
T: DowncastType,
T.Source§fn downcast_ref<T>(&self) -> Option<&T>where
T: DowncastType,
fn downcast_ref<T>(&self) -> Option<&T>where
T: DowncastType,
T when its key matches.Source§fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: DowncastType,
fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: DowncastType,
T when its key matches.Source§impl<T> EntityEventSource for Twhere
T: Entity,
impl<T> EntityEventSource for Twhere
T: Entity,
Source§fn as_entity_event_source(&self) -> &(dyn Entity + 'static)
fn as_entity_event_source(&self) -> &(dyn Entity + 'static)
Source§impl<T> ErasedType for Twhere
T: DowncastType,
impl<T> ErasedType for Twhere
T: DowncastType,
fn downcast_type_key(&self) -> DowncastTypeKey
fn downcast_data(&self) -> *const ()
fn downcast_data_mut(&mut self) -> *mut ()
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreArc<SyncMutex<>>