#[repr(i32)]pub enum InventoryMode {
Hauled = 0,
Weapon = 1,
Worn = 2,
Piercing = 3,
Flask = 4,
WrappedAround = 5,
StuckIn = 6,
InMouth = 7,
Pet = 8,
SewnInto = 9,
Strapped = 10,
}Variants§
Hauled = 0
Weapon = 1
also shield, crutch
Worn = 2
quiver
Piercing = 3
Flask = 4
attached to clothing
WrappedAround = 5
e.g. bandage
StuckIn = 6
InMouth = 7
string descr like Worn
Pet = 8
Left shoulder, right shoulder, or head, selected randomly using pet_seed
SewnInto = 9
Strapped = 10
Implementations§
Source§impl InventoryMode
impl InventoryMode
Source§impl InventoryMode
impl InventoryMode
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 InventoryMode
impl Clone for InventoryMode
Source§fn clone(&self) -> InventoryMode
fn clone(&self) -> InventoryMode
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 InventoryMode
impl Debug for InventoryMode
Source§impl Default for InventoryMode
impl Default for InventoryMode
Source§fn default() -> InventoryMode
fn default() -> InventoryMode
Returns the “default value” for a type. Read more
Source§impl From<InventoryMode> for i32
impl From<InventoryMode> for i32
Source§fn from(value: InventoryMode) -> i32
fn from(value: InventoryMode) -> i32
Converts to this type from the input type.
Source§impl Hash for InventoryMode
impl Hash for InventoryMode
Source§impl Ord for InventoryMode
impl Ord for InventoryMode
Source§fn cmp(&self, other: &InventoryMode) -> Ordering
fn cmp(&self, other: &InventoryMode) -> 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 InventoryMode
impl PartialEq for InventoryMode
Source§impl PartialOrd for InventoryMode
impl PartialOrd for InventoryMode
Source§impl Serialize for InventoryMode
impl Serialize for InventoryMode
Source§impl TryFrom<i32> for InventoryMode
impl TryFrom<i32> for InventoryMode
Source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
The type returned in the event of a conversion error.
Source§fn try_from(value: i32) -> Result<InventoryMode, UnknownEnumValue>
fn try_from(value: i32) -> Result<InventoryMode, UnknownEnumValue>
Performs the conversion.
impl Copy for InventoryMode
impl Eq for InventoryMode
impl StructuralPartialEq for InventoryMode
Auto Trait Implementations§
impl Freeze for InventoryMode
impl RefUnwindSafe for InventoryMode
impl Send for InventoryMode
impl Sync for InventoryMode
impl Unpin for InventoryMode
impl UnsafeUnpin for InventoryMode
impl UnwindSafe for InventoryMode
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