Struct dfhack_proto::messages::MapBlock
source · [−]pub struct MapBlock {Show 29 fields
pub tiles: Vec<i32>,
pub materials: RepeatedField<MatPair>,
pub layer_materials: RepeatedField<MatPair>,
pub vein_materials: RepeatedField<MatPair>,
pub base_materials: RepeatedField<MatPair>,
pub magma: Vec<i32>,
pub water: Vec<i32>,
pub hidden: Vec<bool>,
pub light: Vec<bool>,
pub subterranean: Vec<bool>,
pub outside: Vec<bool>,
pub aquifer: Vec<bool>,
pub water_stagnant: Vec<bool>,
pub water_salt: Vec<bool>,
pub construction_items: RepeatedField<MatPair>,
pub buildings: RepeatedField<BuildingInstance>,
pub tree_percent: Vec<i32>,
pub tree_x: Vec<i32>,
pub tree_y: Vec<i32>,
pub tree_z: Vec<i32>,
pub tile_dig_designation: Vec<TileDigDesignation>,
pub spatterPile: RepeatedField<SpatterPile>,
pub items: RepeatedField<Item>,
pub tile_dig_designation_marker: Vec<bool>,
pub tile_dig_designation_auto: Vec<bool>,
pub grass_percent: Vec<i32>,
pub flows: RepeatedField<FlowInfo>,
pub unknown_fields: UnknownFields,
pub cached_size: CachedSize,
/* private fields */
}Fields
tiles: Vec<i32>materials: RepeatedField<MatPair>layer_materials: RepeatedField<MatPair>vein_materials: RepeatedField<MatPair>base_materials: RepeatedField<MatPair>magma: Vec<i32>water: Vec<i32>light: Vec<bool>subterranean: Vec<bool>outside: Vec<bool>aquifer: Vec<bool>water_stagnant: Vec<bool>water_salt: Vec<bool>construction_items: RepeatedField<MatPair>buildings: RepeatedField<BuildingInstance>tree_percent: Vec<i32>tree_x: Vec<i32>tree_y: Vec<i32>tree_z: Vec<i32>tile_dig_designation: Vec<TileDigDesignation>spatterPile: RepeatedField<SpatterPile>items: RepeatedField<Item>tile_dig_designation_marker: Vec<bool>tile_dig_designation_auto: Vec<bool>grass_percent: Vec<i32>flows: RepeatedField<FlowInfo>unknown_fields: UnknownFieldscached_size: CachedSizeImplementations
sourceimpl MapBlock
impl MapBlock
pub fn new() -> MapBlock
pub fn get_map_x(&self) -> i32
pub fn clear_map_x(&mut self)
pub fn has_map_x(&self) -> bool
pub fn set_map_x(&mut self, v: i32)
pub fn get_map_y(&self) -> i32
pub fn clear_map_y(&mut self)
pub fn has_map_y(&self) -> bool
pub fn set_map_y(&mut self, v: i32)
pub fn get_map_z(&self) -> i32
pub fn clear_map_z(&mut self)
pub fn has_map_z(&self) -> bool
pub fn set_map_z(&mut self, v: i32)
pub fn get_tiles(&self) -> &[i32]
pub fn clear_tiles(&mut self)
pub fn set_tiles(&mut self, v: Vec<i32>)
pub fn mut_tiles(&mut self) -> &mut Vec<i32>
pub fn take_tiles(&mut self) -> Vec<i32>
pub fn get_materials(&self) -> &[MatPair]
pub fn clear_materials(&mut self)
pub fn set_materials(&mut self, v: RepeatedField<MatPair>)
pub fn mut_materials(&mut self) -> &mut RepeatedField<MatPair>
pub fn take_materials(&mut self) -> RepeatedField<MatPair>
pub fn get_layer_materials(&self) -> &[MatPair]
pub fn clear_layer_materials(&mut self)
pub fn set_layer_materials(&mut self, v: RepeatedField<MatPair>)
pub fn mut_layer_materials(&mut self) -> &mut RepeatedField<MatPair>
pub fn take_layer_materials(&mut self) -> RepeatedField<MatPair>
pub fn get_vein_materials(&self) -> &[MatPair]
pub fn clear_vein_materials(&mut self)
pub fn set_vein_materials(&mut self, v: RepeatedField<MatPair>)
pub fn mut_vein_materials(&mut self) -> &mut RepeatedField<MatPair>
pub fn take_vein_materials(&mut self) -> RepeatedField<MatPair>
pub fn get_base_materials(&self) -> &[MatPair]
pub fn clear_base_materials(&mut self)
pub fn set_base_materials(&mut self, v: RepeatedField<MatPair>)
pub fn mut_base_materials(&mut self) -> &mut RepeatedField<MatPair>
pub fn take_base_materials(&mut self) -> RepeatedField<MatPair>
pub fn get_magma(&self) -> &[i32]
pub fn clear_magma(&mut self)
pub fn set_magma(&mut self, v: Vec<i32>)
pub fn mut_magma(&mut self) -> &mut Vec<i32>
pub fn take_magma(&mut self) -> Vec<i32>
pub fn get_water(&self) -> &[i32]
pub fn clear_water(&mut self)
pub fn set_water(&mut self, v: Vec<i32>)
pub fn mut_water(&mut self) -> &mut Vec<i32>
pub fn take_water(&mut self) -> Vec<i32>
pub fn get_light(&self) -> &[bool]
pub fn clear_light(&mut self)
pub fn set_light(&mut self, v: Vec<bool>)
pub fn mut_light(&mut self) -> &mut Vec<bool>
pub fn take_light(&mut self) -> Vec<bool>
pub fn get_subterranean(&self) -> &[bool]
pub fn clear_subterranean(&mut self)
pub fn set_subterranean(&mut self, v: Vec<bool>)
pub fn mut_subterranean(&mut self) -> &mut Vec<bool>
pub fn take_subterranean(&mut self) -> Vec<bool>
pub fn get_outside(&self) -> &[bool]
pub fn clear_outside(&mut self)
pub fn set_outside(&mut self, v: Vec<bool>)
pub fn mut_outside(&mut self) -> &mut Vec<bool>
pub fn take_outside(&mut self) -> Vec<bool>
pub fn get_aquifer(&self) -> &[bool]
pub fn clear_aquifer(&mut self)
pub fn set_aquifer(&mut self, v: Vec<bool>)
pub fn mut_aquifer(&mut self) -> &mut Vec<bool>
pub fn take_aquifer(&mut self) -> Vec<bool>
pub fn get_water_stagnant(&self) -> &[bool]
pub fn clear_water_stagnant(&mut self)
pub fn set_water_stagnant(&mut self, v: Vec<bool>)
pub fn mut_water_stagnant(&mut self) -> &mut Vec<bool>
pub fn take_water_stagnant(&mut self) -> Vec<bool>
pub fn get_water_salt(&self) -> &[bool]
pub fn clear_water_salt(&mut self)
pub fn set_water_salt(&mut self, v: Vec<bool>)
pub fn mut_water_salt(&mut self) -> &mut Vec<bool>
pub fn take_water_salt(&mut self) -> Vec<bool>
pub fn get_construction_items(&self) -> &[MatPair]
pub fn clear_construction_items(&mut self)
pub fn set_construction_items(&mut self, v: RepeatedField<MatPair>)
pub fn mut_construction_items(&mut self) -> &mut RepeatedField<MatPair>
pub fn take_construction_items(&mut self) -> RepeatedField<MatPair>
pub fn get_buildings(&self) -> &[BuildingInstance]
pub fn clear_buildings(&mut self)
pub fn set_buildings(&mut self, v: RepeatedField<BuildingInstance>)
pub fn mut_buildings(&mut self) -> &mut RepeatedField<BuildingInstance>
pub fn take_buildings(&mut self) -> RepeatedField<BuildingInstance>
pub fn get_tree_percent(&self) -> &[i32]
pub fn clear_tree_percent(&mut self)
pub fn set_tree_percent(&mut self, v: Vec<i32>)
pub fn mut_tree_percent(&mut self) -> &mut Vec<i32>
pub fn take_tree_percent(&mut self) -> Vec<i32>
pub fn get_tree_x(&self) -> &[i32]
pub fn clear_tree_x(&mut self)
pub fn set_tree_x(&mut self, v: Vec<i32>)
pub fn mut_tree_x(&mut self) -> &mut Vec<i32>
pub fn take_tree_x(&mut self) -> Vec<i32>
pub fn get_tree_y(&self) -> &[i32]
pub fn clear_tree_y(&mut self)
pub fn set_tree_y(&mut self, v: Vec<i32>)
pub fn mut_tree_y(&mut self) -> &mut Vec<i32>
pub fn take_tree_y(&mut self) -> Vec<i32>
pub fn get_tree_z(&self) -> &[i32]
pub fn clear_tree_z(&mut self)
pub fn set_tree_z(&mut self, v: Vec<i32>)
pub fn mut_tree_z(&mut self) -> &mut Vec<i32>
pub fn take_tree_z(&mut self) -> Vec<i32>
pub fn get_tile_dig_designation(&self) -> &[TileDigDesignation]
pub fn clear_tile_dig_designation(&mut self)
pub fn set_tile_dig_designation(&mut self, v: Vec<TileDigDesignation>)
pub fn mut_tile_dig_designation(&mut self) -> &mut Vec<TileDigDesignation>
pub fn take_tile_dig_designation(&mut self) -> Vec<TileDigDesignation>
pub fn get_spatterPile(&self) -> &[SpatterPile]
pub fn clear_spatterPile(&mut self)
pub fn set_spatterPile(&mut self, v: RepeatedField<SpatterPile>)
pub fn mut_spatterPile(&mut self) -> &mut RepeatedField<SpatterPile>
pub fn take_spatterPile(&mut self) -> RepeatedField<SpatterPile>
pub fn get_items(&self) -> &[Item]
pub fn clear_items(&mut self)
pub fn set_items(&mut self, v: RepeatedField<Item>)
pub fn mut_items(&mut self) -> &mut RepeatedField<Item>
pub fn take_items(&mut self) -> RepeatedField<Item>
pub fn get_tile_dig_designation_marker(&self) -> &[bool]
pub fn clear_tile_dig_designation_marker(&mut self)
pub fn set_tile_dig_designation_marker(&mut self, v: Vec<bool>)
pub fn mut_tile_dig_designation_marker(&mut self) -> &mut Vec<bool>
pub fn take_tile_dig_designation_marker(&mut self) -> Vec<bool>
pub fn get_tile_dig_designation_auto(&self) -> &[bool]
pub fn clear_tile_dig_designation_auto(&mut self)
pub fn set_tile_dig_designation_auto(&mut self, v: Vec<bool>)
pub fn mut_tile_dig_designation_auto(&mut self) -> &mut Vec<bool>
pub fn take_tile_dig_designation_auto(&mut self) -> Vec<bool>
pub fn get_grass_percent(&self) -> &[i32]
pub fn clear_grass_percent(&mut self)
pub fn set_grass_percent(&mut self, v: Vec<i32>)
pub fn mut_grass_percent(&mut self) -> &mut Vec<i32>
pub fn take_grass_percent(&mut self) -> Vec<i32>
pub fn get_flows(&self) -> &[FlowInfo]
pub fn clear_flows(&mut self)
pub fn set_flows(&mut self, v: RepeatedField<FlowInfo>)
pub fn mut_flows(&mut self) -> &mut RepeatedField<FlowInfo>
pub fn take_flows(&mut self) -> RepeatedField<FlowInfo>
Trait Implementations
sourceimpl Message for MapBlock
impl Message for MapBlock
sourcefn is_initialized(&self) -> bool
fn is_initialized(&self) -> bool
True iff all required fields are initialized.
Always returns true for protobuf 3. Read more
sourcefn merge_from(&mut self, is: &mut CodedInputStream<'_>) -> ProtobufResult<()>
fn merge_from(&mut self, is: &mut CodedInputStream<'_>) -> ProtobufResult<()>
Update this message object with fields read from given stream.
sourcefn compute_size(&self) -> u32
fn compute_size(&self) -> u32
Compute and cache size of this message and all nested messages
sourcefn write_to_with_cached_sizes(
&self,
os: &mut CodedOutputStream<'_>
) -> ProtobufResult<()>
fn write_to_with_cached_sizes(
&self,
os: &mut CodedOutputStream<'_>
) -> ProtobufResult<()>
Write message to the stream. Read more
sourcefn get_cached_size(&self) -> u32
fn get_cached_size(&self) -> u32
Get size previously computed by compute_size.
sourcefn get_unknown_fields(&self) -> &UnknownFields
fn get_unknown_fields(&self) -> &UnknownFields
Get a reference to unknown fields.
sourcefn mut_unknown_fields(&mut self) -> &mut UnknownFields
fn mut_unknown_fields(&mut self) -> &mut UnknownFields
Get a mutable reference to unknown fields.
sourcefn as_any_mut(&mut self) -> &mut dyn Any
fn as_any_mut(&mut self) -> &mut dyn Any
View self as mutable Any.
sourcefn descriptor(&self) -> &'static MessageDescriptor
fn descriptor(&self) -> &'static MessageDescriptor
Message descriptor for this message, used for reflection.
sourcefn descriptor_static() -> &'static MessageDescriptor
fn descriptor_static() -> &'static MessageDescriptor
Get message descriptor for message type. Read more
sourcefn default_instance() -> &'static MapBlock
fn default_instance() -> &'static MapBlock
Return a pointer to default immutable message with static lifetime. Read more
sourcefn parse_from(is: &mut CodedInputStream<'_>) -> Result<Self, ProtobufError>
fn parse_from(is: &mut CodedInputStream<'_>) -> Result<Self, ProtobufError>
Parse message from stream.
sourcefn write_to(&self, os: &mut CodedOutputStream<'_>) -> Result<(), ProtobufError>
fn write_to(&self, os: &mut CodedOutputStream<'_>) -> Result<(), ProtobufError>
Write the message to the stream. Read more
sourcefn write_length_delimited_to(
&self,
os: &mut CodedOutputStream<'_>
) -> Result<(), ProtobufError>
fn write_length_delimited_to(
&self,
os: &mut CodedOutputStream<'_>
) -> Result<(), ProtobufError>
Write the message to the stream prepending the message with message length encoded as varint. Read more
sourcefn write_length_delimited_to_vec(
&self,
vec: &mut Vec<u8, Global>
) -> Result<(), ProtobufError>
fn write_length_delimited_to_vec(
&self,
vec: &mut Vec<u8, Global>
) -> Result<(), ProtobufError>
Write the message to the vec, prepend the message with message length encoded as varint. Read more
sourcefn merge_from_bytes(&mut self, bytes: &[u8]) -> Result<(), ProtobufError>
fn merge_from_bytes(&mut self, bytes: &[u8]) -> Result<(), ProtobufError>
Update this message object with fields read from given stream.
sourcefn parse_from_reader(reader: &mut dyn Read) -> Result<Self, ProtobufError>
fn parse_from_reader(reader: &mut dyn Read) -> Result<Self, ProtobufError>
Parse message from reader. Parse stops on EOF or when error encountered. Read more
sourcefn parse_from_bytes(bytes: &[u8]) -> Result<Self, ProtobufError>
fn parse_from_bytes(bytes: &[u8]) -> Result<Self, ProtobufError>
Parse message from byte array.
sourcefn check_initialized(&self) -> Result<(), ProtobufError>
fn check_initialized(&self) -> Result<(), ProtobufError>
Check if all required fields of this object are initialized.
sourcefn write_to_writer(&self, w: &mut dyn Write) -> Result<(), ProtobufError>
fn write_to_writer(&self, w: &mut dyn Write) -> Result<(), ProtobufError>
Write the message to the writer.
sourcefn write_to_vec(&self, v: &mut Vec<u8, Global>) -> Result<(), ProtobufError>
fn write_to_vec(&self, v: &mut Vec<u8, Global>) -> Result<(), ProtobufError>
Write the message to bytes vec.
sourcefn write_to_bytes(&self) -> Result<Vec<u8, Global>, ProtobufError>
fn write_to_bytes(&self) -> Result<Vec<u8, Global>, ProtobufError>
Write the message to bytes vec.
sourcefn write_length_delimited_to_writer(
&self,
w: &mut dyn Write
) -> Result<(), ProtobufError>
fn write_length_delimited_to_writer(
&self,
w: &mut dyn Write
) -> Result<(), ProtobufError>
Write the message to the writer, prepend the message with message length encoded as varint. Read more
sourcefn write_length_delimited_to_bytes(
&self
) -> Result<Vec<u8, Global>, ProtobufError>
fn write_length_delimited_to_bytes(
&self
) -> Result<Vec<u8, Global>, ProtobufError>
Write the message to the bytes vec, prepend the message with message length encoded as varint. Read more
sourceimpl ProtobufValue for MapBlock
impl ProtobufValue for MapBlock
sourcefn as_ref(&self) -> ReflectValueRef<'_>
fn as_ref(&self) -> ReflectValueRef<'_>
As ref
sourcefn is_non_zero(&self) -> bool
fn is_non_zero(&self) -> bool
Is value non-zero?
sourcefn as_ref_copy(&self) -> ReflectValueRef<'static>
fn as_ref_copy(&self) -> ReflectValueRef<'static>
Return ProtobufValueRef if self is Copy. Read more
impl StructuralPartialEq for MapBlock
Auto Trait Implementations
impl RefUnwindSafe for MapBlock
impl Send for MapBlock
impl Sync for MapBlock
impl Unpin for MapBlock
impl UnwindSafe for MapBlock
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more