pub enum Event {
Show 48 variants
Draw {
player: u8,
card: CardId,
},
Damage {
player: u8,
card: CardId,
},
DamageCancel {
player: u8,
},
DamageIntent {
event_id: u32,
source_player: u8,
source_slot: Option<u8>,
target: u8,
amount: i32,
damage_type: DamageType,
cancelable: bool,
},
DamageModifierApplied {
event_id: u32,
modifier: DamageModifierKind,
before_amount: i32,
after_amount: i32,
before_cancelable: bool,
after_cancelable: bool,
before_canceled: bool,
after_canceled: bool,
},
DamageModified {
event_id: u32,
target: u8,
original: i32,
modified: i32,
canceled: bool,
damage_type: DamageType,
},
DamageCommitted {
event_id: u32,
target: u8,
card: CardId,
damage_type: DamageType,
},
ReversalCommitted {
player: u8,
slot: u8,
cause_damage_event: Option<u32>,
},
Reveal {
player: u8,
card: CardId,
reason: RevealReason,
audience: RevealAudience,
},
TriggerQueued {
trigger_id: u32,
group_id: u32,
player: u8,
source: CardId,
effect: TriggerEffect,
},
TriggerGrouped {
group_id: u32,
trigger_ids: Vec<u32>,
},
TriggerResolved {
trigger_id: u32,
player: u8,
effect: TriggerEffect,
},
TriggerCanceled {
trigger_id: u32,
player: u8,
reason: TriggerCancelReason,
},
TimingWindowEntered {
window: TimingWindow,
player: u8,
},
PriorityGranted {
window: TimingWindow,
player: u8,
},
PriorityPassed {
player: u8,
window: TimingWindow,
pass_count: u8,
},
StackGroupPresented {
group_id: u32,
controller: u8,
items: Vec<StackItem>,
},
StackOrderChosen {
group_id: u32,
controller: u8,
stack_id: u32,
},
StackPushed {
item: StackItem,
},
StackResolved {
item: StackItem,
},
AutoResolveCapExceeded {
cap: u32,
stack_len: u32,
window: Option<TimingWindow>,
},
WindowAdvanced {
from: TimingWindow,
to: Option<TimingWindow>,
},
ChoicePresented {
choice_id: u32,
player: u8,
reason: ChoiceReason,
options: Vec<ChoiceOptionSnapshot>,
total_candidates: u16,
page_start: u16,
},
ChoicePageChanged {
choice_id: u32,
player: u8,
from_start: u16,
to_start: u16,
},
ChoiceMade {
choice_id: u32,
player: u8,
reason: ChoiceReason,
option: ChoiceOptionRef,
},
ChoiceAutopicked {
choice_id: u32,
player: u8,
reason: ChoiceReason,
option: ChoiceOptionRef,
},
ChoiceSkipped {
choice_id: u32,
player: u8,
reason: ChoiceReason,
skip_reason: ChoiceSkipReason,
},
ZoneMove {
player: u8,
card: CardId,
from: Zone,
to: Zone,
from_slot: Option<u8>,
to_slot: Option<u8>,
},
ControlChanged {
card: CardId,
owner: u8,
from_controller: u8,
to_controller: u8,
from_slot: u8,
to_slot: u8,
},
ModifierAdded {
id: u32,
source: CardId,
target_player: u8,
target_slot: u8,
target_card: CardId,
kind: ModifierKind,
magnitude: i32,
duration: ModifierDuration,
},
ModifierRemoved {
id: u32,
reason: ModifierRemoveReason,
},
Concede {
player: u8,
},
Play {
player: u8,
card: CardId,
slot: u8,
},
PlayEvent {
player: u8,
card: CardId,
},
PlayClimax {
player: u8,
card: CardId,
},
Trigger {
player: u8,
icon: TriggerIcon,
card: Option<CardId>,
},
Attack {
player: u8,
slot: u8,
},
AttackType {
player: u8,
attacker_slot: u8,
attack_type: AttackType,
},
Counter {
player: u8,
card: CardId,
power: i32,
},
Clock {
player: u8,
card: Option<CardId>,
},
Shuffle {
player: u8,
zone: Zone,
},
Refresh {
player: u8,
},
RefreshPenalty {
player: u8,
card: CardId,
},
LevelUpChoice {
player: u8,
card: CardId,
},
Encore {
player: u8,
slot: u8,
kept: bool,
},
Stand {
player: u8,
},
EndTurn {
player: u8,
},
Terminal {
winner: Option<u8>,
},
}Variants§
Draw
Damage
DamageCancel
DamageIntent
Fields
§
damage_type: DamageTypeDamageModifierApplied
Fields
§
modifier: DamageModifierKindDamageModified
DamageCommitted
ReversalCommitted
Reveal
TriggerQueued
TriggerGrouped
TriggerResolved
TriggerCanceled
TimingWindowEntered
PriorityGranted
PriorityPassed
StackGroupPresented
StackOrderChosen
StackPushed
StackResolved
AutoResolveCapExceeded
WindowAdvanced
ChoicePresented
ChoicePageChanged
ChoiceMade
ChoiceAutopicked
ChoiceSkipped
ZoneMove
ControlChanged
ModifierAdded
ModifierRemoved
Concede
Play
PlayEvent
PlayClimax
Trigger
Attack
AttackType
Counter
Clock
Shuffle
Refresh
RefreshPenalty
LevelUpChoice
Encore
Stand
EndTurn
Terminal
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Event
impl<'de> Deserialize<'de> for Event
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Event
impl RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnwindSafe for Event
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<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 more