Skip to main content

ExplosionBlockReader

Trait ExplosionBlockReader 

Source
pub(crate) trait ExplosionBlockReader: Sync {
    // Required method
    fn block_state(&self, pos: BlockPos) -> Option<BlockStateId>;
}
Expand description

State-only view available to explicitly immutable explosion block calculators.

Keeping this surface narrow prevents worker tasks from reaching mutable world, entity, block-entity, or general crate::world::LevelReader behavior.

Required Methods§

Source

fn block_state(&self, pos: BlockPos) -> Option<BlockStateId>

Returns None when pos is outside a bounded reader’s stable view.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§