#[repr(i32)]pub enum TileDigDesignation {
NoDig = 0,
DefaultDig = 1,
UpDownStairDig = 2,
ChannelDig = 3,
RampDig = 4,
DownStairDig = 5,
UpStairDig = 6,
}Variants§
NoDig = 0
no designation
DefaultDig = 1
dig walls, remove stairs and ramps, gather plants, fell trees
UpDownStairDig = 2
ChannelDig = 3
RampDig = 4
DownStairDig = 5
UpStairDig = 6
Implementations§
Source§impl TileDigDesignation
impl TileDigDesignation
Sourcepub fn from_i32(value: i32) -> Option<TileDigDesignation>
👎Deprecated: Use the TryFrom<i32> implementation instead
pub fn from_i32(value: i32) -> Option<TileDigDesignation>
Use the TryFrom<i32> implementation instead
Converts an i32 to a TileDigDesignation, or None if value is not a valid variant.
Source§impl TileDigDesignation
impl TileDigDesignation
Sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
Sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
Source§impl Clone for TileDigDesignation
impl Clone for TileDigDesignation
Source§fn clone(&self) -> TileDigDesignation
fn clone(&self) -> TileDigDesignation
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TileDigDesignation
impl Debug for TileDigDesignation
Source§impl Default for TileDigDesignation
impl Default for TileDigDesignation
Source§fn default() -> TileDigDesignation
fn default() -> TileDigDesignation
Returns the “default value” for a type. Read more
Source§impl From<TileDigDesignation> for i32
impl From<TileDigDesignation> for i32
Source§fn from(value: TileDigDesignation) -> i32
fn from(value: TileDigDesignation) -> i32
Converts to this type from the input type.
Source§impl Hash for TileDigDesignation
impl Hash for TileDigDesignation
Source§impl Ord for TileDigDesignation
impl Ord for TileDigDesignation
Source§fn cmp(&self, other: &TileDigDesignation) -> Ordering
fn cmp(&self, other: &TileDigDesignation) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for TileDigDesignation
impl PartialEq for TileDigDesignation
Source§impl PartialOrd for TileDigDesignation
impl PartialOrd for TileDigDesignation
Source§impl Serialize for TileDigDesignation
impl Serialize for TileDigDesignation
Source§impl TryFrom<i32> for TileDigDesignation
impl TryFrom<i32> for TileDigDesignation
Source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
The type returned in the event of a conversion error.
Source§fn try_from(value: i32) -> Result<TileDigDesignation, UnknownEnumValue>
fn try_from(value: i32) -> Result<TileDigDesignation, UnknownEnumValue>
Performs the conversion.
impl Copy for TileDigDesignation
impl Eq for TileDigDesignation
impl StructuralPartialEq for TileDigDesignation
Auto Trait Implementations§
impl Freeze for TileDigDesignation
impl RefUnwindSafe for TileDigDesignation
impl Send for TileDigDesignation
impl Sync for TileDigDesignation
impl Unpin for TileDigDesignation
impl UnsafeUnpin for TileDigDesignation
impl UnwindSafe for TileDigDesignation
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