Struct BlockProperties
pub struct BlockProperties {
pub hardness: Option<f32>,
pub explosion_resistance: Option<f32>,
pub light: Option<u8>,
pub requires_tool: Option<bool>,
pub friction: Option<f32>,
pub map_color: Option<u8>,
pub sounds: Option<String>,
pub random_ticks: Option<RandomTicks>,
pub render_shape: Option<RenderShape>,
pub push_reaction: Option<PushReaction>,
pub occludes: Option<bool>,
pub destroy_overlay: Option<bool>,
}Expand description
BlockProperties in a load-time content declaration.
Fields§
§hardness: Option<f32>Destroy time in seconds of hand mining (-1: unbreakable).
explosion_resistance: Option<f32>Explosion resistance; unset inherits the template.
light: Option<u8>Light emitted, 0 to 15.
requires_tool: Option<bool>Whether drops require the appropriate tool.
friction: Option<f32>Surface friction; unset inherits the template.
map_color: Option<u8>A MapColor id, 0 to 61.
sounds: Option<String>A vanilla block whose sounds this block uses.
random_ticks: Option<RandomTicks>Which states tick randomly, whatever the template does (isRandomlyTicking).
render_shape: Option<RenderShape>How the block is drawn, whatever the template does (BlockBehaviour.getRenderShape).
push_reaction: Option<PushReaction>Vanilla’s piston push reaction, or the template’s when unset.
occludes: Option<bool>false: the block occludes nothing, so its neighbours’ faces are drawn and light passes
it (BlockBehaviour.Properties.noOcclusion); unset or true: as its template.
destroy_overlay: Option<bool>false: the breaking crack (destroy_stage_0..9) is not drawn on the block, as for a
block broken by use; unset or true, it is drawn. Only the overlay: the break and the
destroy-progress packets are vanilla’s.
Trait Implementations§
§impl Clone for BlockProperties
impl Clone for BlockProperties
§fn clone(&self) -> BlockProperties
fn clone(&self) -> BlockProperties
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more