Enum genius_invokation::DeckError
source · pub enum DeckError {
TooManyCharacterCards,
TooManyActionCards,
NotEnoughCharacterCards(u8),
NotEnoughActionCards(u8),
TalentRequiresCharacter(TalentCard),
CharacterAppearsMoreThanOnce(CharacterCard),
ActionCardAppearsMoreThanTwice(ActionCard),
}Variants§
TooManyCharacterCards
Character cards > 3
TooManyActionCards
Action cards > 30
NotEnoughCharacterCards(u8)
Character cards < 3 (u8 represents current amount)
NotEnoughActionCards(u8)
Action cards < 30 (u8 represents current amount)
TalentRequiresCharacter(TalentCard)
Talent card is present, but its CharacterCard requirement is not
CharacterAppearsMoreThanOnce(CharacterCard)
Deck must include three different character cards
ActionCardAppearsMoreThanTwice(ActionCard)
Only one or two of the same action card allowed for a deck
Trait Implementations§
source§impl Error for DeckError
impl Error for DeckError
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()