#[repr(i32)]pub enum EncounterEventKind {
Unspecified = 0,
Spawn = 1,
Movement = 2,
Death = 3,
Despawn = 4,
TargetChange = 5,
PullTransition = 6,
}Variants§
Implementations§
Source§impl EncounterEventKind
impl EncounterEventKind
Sourcepub fn from_i32(value: i32) -> Option<EncounterEventKind>
👎Deprecated: Use the TryFrom<i32> implementation instead
pub fn from_i32(value: i32) -> Option<EncounterEventKind>
Use the TryFrom<i32> implementation instead
Converts an i32 to a EncounterEventKind, or None if value is not a valid variant.
Source§impl EncounterEventKind
impl EncounterEventKind
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 EncounterEventKind
impl Clone for EncounterEventKind
Source§fn clone(&self) -> EncounterEventKind
fn clone(&self) -> EncounterEventKind
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 EncounterEventKind
impl Debug for EncounterEventKind
Source§impl Default for EncounterEventKind
impl Default for EncounterEventKind
Source§fn default() -> EncounterEventKind
fn default() -> EncounterEventKind
Returns the “default value” for a type. Read more
Source§impl From<EncounterEventKind> for i32
impl From<EncounterEventKind> for i32
Source§fn from(value: EncounterEventKind) -> i32
fn from(value: EncounterEventKind) -> i32
Converts to this type from the input type.
Source§impl Hash for EncounterEventKind
impl Hash for EncounterEventKind
Source§impl Ord for EncounterEventKind
impl Ord for EncounterEventKind
Source§fn cmp(&self, other: &EncounterEventKind) -> Ordering
fn cmp(&self, other: &EncounterEventKind) -> 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 EncounterEventKind
impl PartialEq for EncounterEventKind
Source§impl PartialOrd for EncounterEventKind
impl PartialOrd for EncounterEventKind
Source§impl TryFrom<i32> for EncounterEventKind
impl TryFrom<i32> for EncounterEventKind
Source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
The type returned in the event of a conversion error.
Source§fn try_from(value: i32) -> Result<EncounterEventKind, UnknownEnumValue>
fn try_from(value: i32) -> Result<EncounterEventKind, UnknownEnumValue>
Performs the conversion.
impl Copy for EncounterEventKind
impl Eq for EncounterEventKind
impl StructuralPartialEq for EncounterEventKind
Auto Trait Implementations§
impl Freeze for EncounterEventKind
impl RefUnwindSafe for EncounterEventKind
impl Send for EncounterEventKind
impl Sync for EncounterEventKind
impl Unpin for EncounterEventKind
impl UnsafeUnpin for EncounterEventKind
impl UnwindSafe for EncounterEventKind
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