pub enum ActivateResult {
BlockActivated,
ItemPlaced,
ItemUsed,
ItemInteracted,
}
Expand description
The possible results of successfully right-clicking on a location.
Variants§
BlockActivated
A usable block, such as a lever or button, was activated.
ItemPlaced
The equipped inventory item, such as a block of dirt, a torch, a spawn egg, or a fire charge, was placed into the world.
ItemUsed
The equipped inventory item, such as a water bucket or an empty bucket when facing a fluid, was used in a way other than placing a block into the world.
ItemInteracted
The equipped inventory item, such as shears, was used on an adjacent entity.
Trait Implementations§
Source§impl Clone for ActivateResult
impl Clone for ActivateResult
Source§fn clone(&self) -> ActivateResult
fn clone(&self) -> ActivateResult
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 ActivateResult
impl Debug for ActivateResult
Source§impl Hash for ActivateResult
impl Hash for ActivateResult
Source§impl Ord for ActivateResult
impl Ord for ActivateResult
Source§fn cmp(&self, other: &ActivateResult) -> Ordering
fn cmp(&self, other: &ActivateResult) -> 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 ActivateResult
impl PartialEq for ActivateResult
Source§impl PartialOrd for ActivateResult
impl PartialOrd for ActivateResult
impl Copy for ActivateResult
impl Eq for ActivateResult
impl StructuralPartialEq for ActivateResult
Auto Trait Implementations§
impl Freeze for ActivateResult
impl RefUnwindSafe for ActivateResult
impl Send for ActivateResult
impl Sync for ActivateResult
impl Unpin for ActivateResult
impl UnwindSafe for ActivateResult
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