#[repr(transparent)]pub struct BlockKind(pub u32);
Tuple Fields§
§0: u32
Implementations§
Source§impl BlockKind
impl BlockKind
pub const DEFAULT_SLIP: f64 = 0.59999999999999998f64
pub const LADDER: BlockKind
pub const LEAVES: BlockKind
pub const FLOWING_WATER: BlockKind
pub const STONE: BlockKind
pub const DIRT: BlockKind
pub const GLASS: BlockKind
pub fn id(self) -> u32
pub fn hardness(&self, blocks: &BlockData) -> Option<f64>
pub fn data<'a>(&self, blocks: &'a BlockData) -> &'a Block
pub fn throw_away_block(self) -> bool
pub fn mineable(&self, blocks: &BlockData) -> bool
pub fn slip(&self) -> f64
Trait Implementations§
impl Copy for BlockKind
impl Eq for BlockKind
impl StructuralPartialEq for BlockKind
Auto Trait Implementations§
impl Freeze for BlockKind
impl RefUnwindSafe for BlockKind
impl Send for BlockKind
impl Sync for BlockKind
impl Unpin for BlockKind
impl UnwindSafe for BlockKind
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
Converts
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>
Converts
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 more