Enum roguelike::Action
[−]
[src]
pub enum Action {
PickedSword(usize, usize),
PickedGold(usize, usize),
KilledEnemy(usize, usize),
AttackedEnemy(usize, usize),
Nothing,
Won,
WalkedIntoWall,
}An Action represents something that happened, meta-data about the last move if you will. You could've picked something up, attacked or killed an enemy, walked into a wall or won. Nothing represents that you moved, but nothing happened, meaning you moved into an empty square.
Variants
PickedSword(usize, usize)PickedGold(usize, usize)KilledEnemy(usize, usize)AttackedEnemy(usize, usize)NothingWonWalkedIntoWallTrait Implementations
impl PartialEq for Action[src]
fn eq(&self, __arg_0: &Action) -> bool
This method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, __arg_0: &Action) -> bool
This method tests for !=.
impl Eq for Action[src]
impl Hash for Action[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
Feeds this value into the given [Hasher]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0
H: Hasher,
Feeds a slice of this type into the given [Hasher]. Read more
impl Clone for Action[src]
fn clone(&self) -> Action
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0
Performs copy-assignment from source. Read more