pub struct PhysicsFlags(pub u16);Expand description
Bit set of physics-relevant block flags.
Tuple Fields§
§0: u16Implementations§
Source§impl PhysicsFlags
impl PhysicsFlags
Sourcepub const NONE: PhysicsFlags
pub const NONE: PhysicsFlags
No flags.
Sourcepub const CLIMBABLE: PhysicsFlags
pub const CLIMBABLE: PhysicsFlags
The entity can climb while inside this block (ladder, vine, …).
Sourcepub const WATER: PhysicsFlags
pub const WATER: PhysicsFlags
The block is a water block (still / flowing). In 1.16 waterlogged states are reported by the per-state fluid table instead.
Sourcepub const LAVA: PhysicsFlags
pub const LAVA: PhysicsFlags
The block is a lava block (still / flowing).
Sourcepub const STUCK: PhysicsFlags
pub const STUCK: PhysicsFlags
Entities inside are slowed by the block’s stuck_multiplier (cobweb, sweet berry bush).
Sourcepub const SLIME: PhysicsFlags
pub const SLIME: PhysicsFlags
Slime block: bounces on landing and slows walking.
Sourcepub const BED_BOUNCE: PhysicsFlags
pub const BED_BOUNCE: PhysicsFlags
Bed: bounces on landing (1.12+ behaviour; never set for 1.8).
Sourcepub const HONEY: PhysicsFlags
pub const HONEY: PhysicsFlags
Honey block: wall sliding (1.15+).
Sourcepub const BUBBLE_COLUMN: PhysicsFlags
pub const BUBBLE_COLUMN: PhysicsFlags
Bubble column (1.13+): pushes entities up or down.
Sourcepub const COLLIDE_SLOWDOWN: PhysicsFlags
pub const COLLIDE_SLOWDOWN: PhysicsFlags
1.8 soul sand: speed_factor is applied to horizontal motion when the entity’s box
intersects the block (vanilla Block.onEntityCollision), not as a ground speed factor.
Sourcepub const FENCE: PhysicsFlags
pub const FENCE: PhysicsFlags
Fence: 1.16 #minecraft:fences tag; 1.8 FenceBlock (wooden + nether brick fences).
Sourcepub const WALL: PhysicsFlags
pub const WALL: PhysicsFlags
Wall: 1.16 #minecraft:walls tag; 1.8 WallBlock (cobblestone wall).
Sourcepub const FENCE_GATE: PhysicsFlags
pub const FENCE_GATE: PhysicsFlags
Fence gate: 1.16 #minecraft:fence_gates tag; 1.8 FenceGateBlock.
Sourcepub const TRAPDOOR: PhysicsFlags
pub const TRAPDOOR: PhysicsFlags
Trapdoor: 1.16 #minecraft:trapdoors tag; 1.8 TrapdoorBlock.
Sourcepub const SOUL_SPEED: PhysicsFlags
pub const SOUL_SPEED: PhysicsFlags
1.16 #minecraft:soul_speed_blocks (soul sand, soul soil); never set for 1.8.
Sourcepub const FIRE: PhysicsFlags
pub const FIRE: PhysicsFlags
1.16 #minecraft:fire (fire, soul fire); never set for 1.8.
Sourcepub const fn contains(self, other: PhysicsFlags) -> bool
pub const fn contains(self, other: PhysicsFlags) -> bool
true when every flag of other is set in self.
Sourcepub const fn union(self, other: PhysicsFlags) -> PhysicsFlags
pub const fn union(self, other: PhysicsFlags) -> PhysicsFlags
Union of two flag sets.