struct PeriodicEffectContext<'a> {Show 13 fields
state: &'a mut CombatState,
buf: &'a mut DenseBuffer,
sink: &'a mut TelemetrySink,
rng: &'a mut dyn FnMut() -> f64,
now: SimTime,
local: LocalAuraIdx,
spell_id: u32,
effect_ref: Option<DamageEffectRef>,
may_crit: bool,
damage_is_periodic: bool,
key: AuraKey,
source: ActorId,
target: EnemyIdx,
}Fields§
§state: &'a mut CombatState§buf: &'a mut DenseBuffer§sink: &'a mut TelemetrySink§rng: &'a mut dyn FnMut() -> f64§now: SimTime§local: LocalAuraIdx§spell_id: u32§effect_ref: Option<DamageEffectRef>§may_crit: bool§damage_is_periodic: bool§key: AuraKey§source: ActorId§target: EnemyIdxImplementations§
Source§impl PeriodicEffectContext<'_>
impl PeriodicEffectContext<'_>
fn active_points(&self, initial: f64) -> f64
fn active_amplitude(&self, initial: f64) -> f64
fn damage_stack_multiplier(&self) -> f64
fn combat_ctx(&mut self) -> CombatCtx<'_>
fn remaining_ticks(&self) -> f64
fn classify_damage(&self, flags: DamageFlags) -> DamageFlags
fn damage_ap( &mut self, coef: f64, flags: DamageFlags, snapshot: Option<&DamageSnapshot>, ) -> bool
fn flat_damage(&mut self, amount: f64, is_physical: bool) -> bool
fn rolling_flat_damage(&mut self, amount: f64, is_physical: bool) -> bool
fn rolling_damage_ap(&mut self, coef: f64, flags: DamageFlags) -> bool
fn rolling_damage_sp(&mut self, coef: f64, flags: DamageFlags) -> bool
fn damage_sp( &mut self, coef: f64, flags: DamageFlags, snapshot: Option<&DamageSnapshot>, ) -> bool
fn max_health_damage(&mut self, percent: f64, is_physical: bool) -> bool
fn heal(&mut self, base: f64, ap_coef: f64, sp_coef: f64, percent_of_max: f64)
fn leech( &mut self, base: f64, ap_coef: f64, sp_coef: f64, is_physical: bool, heal_multiplier: f64, ) -> bool
fn gain_resource(&mut self, amount: f64, resource_type: Option<ResourceType>)
fn drain_resource(&mut self, amount: f64) -> bool
fn apply_aura(&mut self, target_aura_local: LocalAuraIdx)
fn deal_residual_damage(&mut self)
fn remove_stack(&mut self) -> bool
Auto Trait Implementations§
impl<'a> Freeze for PeriodicEffectContext<'a>
impl<'a> !RefUnwindSafe for PeriodicEffectContext<'a>
impl<'a> !Send for PeriodicEffectContext<'a>
impl<'a> !Sync for PeriodicEffectContext<'a>
impl<'a> Unpin for PeriodicEffectContext<'a>
impl<'a> UnsafeUnpin for PeriodicEffectContext<'a>
impl<'a> !UnwindSafe for PeriodicEffectContext<'a>
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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