pub enum MoveOutcomeOnTarget {
Unknown,
Failure,
HitSubstitute,
Success,
Damage(u16),
}Expand description
The outcome of a move used on a single target in a single turn of battle.
Differs from MoveOutcome in that it roughly tracks the effect a move had on a single target,
rather than the outcome of the use of the move as a whole.
Variants§
Unknown
It is unknown how the move affected the target.
Failure
The move failed to do anything to the target.
HitSubstitute
The move hit a Substitute.
Success
The move successfully hit the target.
Damage(u16)
The move successfully dealt damage to the target.
Implementations§
Source§impl MoveOutcomeOnTarget
impl MoveOutcomeOnTarget
Sourcepub fn hit_target(&self) -> bool
pub fn hit_target(&self) -> bool
Did the move hit the target as intended?
Trait Implementations§
Source§impl Clone for MoveOutcomeOnTarget
impl Clone for MoveOutcomeOnTarget
Source§fn clone(&self) -> MoveOutcomeOnTarget
fn clone(&self) -> MoveOutcomeOnTarget
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 MoveOutcomeOnTarget
impl Debug for MoveOutcomeOnTarget
Source§impl Default for MoveOutcomeOnTarget
impl Default for MoveOutcomeOnTarget
Source§fn default() -> MoveOutcomeOnTarget
fn default() -> MoveOutcomeOnTarget
Returns the “default value” for a type. Read more
Source§impl From<bool> for MoveOutcomeOnTarget
impl From<bool> for MoveOutcomeOnTarget
Source§impl PartialEq for MoveOutcomeOnTarget
impl PartialEq for MoveOutcomeOnTarget
impl Copy for MoveOutcomeOnTarget
impl Eq for MoveOutcomeOnTarget
impl StructuralPartialEq for MoveOutcomeOnTarget
Auto Trait Implementations§
impl Freeze for MoveOutcomeOnTarget
impl RefUnwindSafe for MoveOutcomeOnTarget
impl Send for MoveOutcomeOnTarget
impl Sync for MoveOutcomeOnTarget
impl Unpin for MoveOutcomeOnTarget
impl UnwindSafe for MoveOutcomeOnTarget
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<'a, 'b, T> UnsafelyDetachBorrow<'a, 'b, T> for T
impl<'a, 'b, T> UnsafelyDetachBorrow<'a, 'b, T> for T
Source§unsafe fn unsafely_detach_borrow(&'a self) -> &'b T
unsafe fn unsafely_detach_borrow(&'a self) -> &'b T
Unsafely detaches an immutable borrow, attaching a new lifetime. Read more
Source§impl<'a, 'b, T> UnsafelyDetachBorrowMut<'a, 'b, T> for T
impl<'a, 'b, T> UnsafelyDetachBorrowMut<'a, 'b, T> for T
Source§unsafe fn unsafely_detach_borrow_mut(&'a mut self) -> &'b mut T
unsafe fn unsafely_detach_borrow_mut(&'a mut self) -> &'b mut T
Unsafely detaches a mutable borrow, attaching a new lifetime. Read more