Struct minetest_protocol::wire::types::MapBlock
source · pub struct MapBlock {
pub is_underground: bool,
pub day_night_diff: bool,
pub generated: bool,
pub lighting_complete: Option<u16>,
pub nodes: MapNodesBulk,
pub node_metadata: NodeMetadataList,
}
Fields§
§is_underground: bool
§day_night_diff: bool
§generated: bool
§lighting_complete: Option<u16>
§nodes: MapNodesBulk
§node_metadata: NodeMetadataList
Trait Implementations§
source§impl Deserialize for MapBlock
impl Deserialize for MapBlock
fn deserialize(deser: &mut Deserializer<'_>) -> DeserializeResult<Self>
source§impl PartialEq<MapBlock> for MapBlock
impl PartialEq<MapBlock> for MapBlock
source§impl Serialize for MapBlock
impl Serialize for MapBlock
source§fn serialize<S: Serializer>(&self, ser: &mut S) -> SerializeResult
fn serialize<S: Serializer>(&self, ser: &mut S) -> SerializeResult
MapBlock is a bit of a nightmare, because the compression algorithm and where the compression is applied (to the whole struct, or to parts of it) depends on the serialization format version.
For now, only ser_fmt >= 28 is supported. For ver 28, only the nodes and nodemeta are compressed using zlib. For >= 29, the entire thing is compressed using zstd.