pub struct CbtEvent {Show 24 fields
pub time: u64,
pub src_agent: u64,
pub dst_agent: u64,
pub value: i32,
pub buff_dmg: i32,
pub overstack_value: u32,
pub skillid: u32,
pub src_instid: u16,
pub dst_instid: u16,
pub src_master_instid: u16,
pub dst_master_instid: u16,
pub iff: IFF,
pub buff: u8,
pub result: CbtResult,
pub is_activation: CbtActivation,
pub is_buffremove: CbtBuffRemove,
pub is_ninety: bool,
pub is_fifty: bool,
pub is_moving: bool,
pub is_statechange: CbtStateChange,
pub is_flanking: bool,
pub is_shields: bool,
pub is_offcycle: bool,
pub padding_end: u32,
}
Expand description
A combat event.
This event combines both the old structure and the new structure. Fields not present in the source are zeroed. When dealing with events, always make sure to check the header.revision tag.
For conflicting data types, the bigger one is chosen (e.g. u32 over u16).
Fields
time: u64
System time since Windows was started, in milliseconds.
src_agent: u64
Unique identifier of the source agent.
dst_agent: u64
Unique identifier of the destination agent.
value: i32
Event-specific value.
buff_dmg: i32
Estimated buff damage. Zero on application event.
overstack_value: u32
Estimated overwritten stack duration for buff application.
skillid: u32
Skill id.
src_instid: u16
Agent map instance id.
dst_instid: u16
Agent map instance id.
src_master_instid: u16
Master source agent map instance id if source is a minion/pet.
dst_master_instid: u16
Master destination agent map instance id if destination is a minion/pet.
iff: IFF
buff: u8
Buff application, removal or damage event.
result: CbtResult
is_activation: CbtActivation
is_buffremove: CbtBuffRemove
is_ninety: bool
Source agent health was over 90%.
is_fifty: bool
Target agent health was under 90%.
is_moving: bool
Source agent was moving.
is_statechange: CbtStateChange
is_flanking: bool
Target agent was not facing source.
is_shields: bool
All or part damage was vs. barrier/shield.
is_offcycle: bool
False if buff dmg happened during tick, true otherwise.
padding_end: u32
Padding for some events.
Trait Implementations
sourceimpl TryFrom<&'_ CbtEvent> for Event
impl TryFrom<&'_ CbtEvent> for Event
sourcefn try_from(raw_event: &CbtEvent) -> Result<Self, Self::Error>
fn try_from(raw_event: &CbtEvent) -> Result<Self, Self::Error>
Transform a raw event to a “high-level” event.
If the event is not known, or some other error occured, None
is
returned.
raw_event
- the raw event to transform.
type Error = FromRawEventError
type Error = FromRawEventError
The type returned in the event of a conversion error.
sourceimpl TryFrom<CbtEvent> for Event
impl TryFrom<CbtEvent> for Event
sourcefn try_from(raw_event: CbtEvent) -> Result<Self, Self::Error>
fn try_from(raw_event: CbtEvent) -> Result<Self, Self::Error>
Convenience method to avoid manual borrowing.
Note that this conversion will consume the event, so if you plan on re-using it, use the
TryFrom<&raw::CbtEvent>
implementation that works with a reference.
type Error = FromRawEventError
type Error = FromRawEventError
The type returned in the event of a conversion error.
impl Eq for CbtEvent
impl StructuralEq for CbtEvent
impl StructuralPartialEq for CbtEvent
Auto Trait Implementations
impl RefUnwindSafe for CbtEvent
impl Send for CbtEvent
impl Sync for CbtEvent
impl Unpin for CbtEvent
impl UnwindSafe for CbtEvent
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more