pub struct ShieldState {
pub value: f32,
pub delay_remaining: f64,
pub full: bool,
pub broken: bool,
pub delayed: bool,
pub recharge_enabled: bool,
pub recharging: bool,
}Expand description
Read-only snapshot. Flags are independent; see the module’s state contract and executable example. No field is an emitted event.
Fields§
§value: f32Stored f32 charge.
delay_remaining: f64Exact remaining simulation delay, retaining the helper’s f64 timer.
full: boolCharge equals maximum, including a zero maximum.
broken: boolCharge is zero, regardless of delay or recharge eligibility.
delayed: boolA positive live delay remains, even if recharge is disabled.
recharge_enabled: boolPositive maximum and rate, independent of charge and delay.
recharging: boolEnabled, below full, and no delay. Does not promise a numerical gain on the next advance, especially for zero dt or sub-ULP increments.
Trait Implementations§
Source§impl Clone for ShieldState
impl Clone for ShieldState
Source§fn clone(&self) -> ShieldState
fn clone(&self) -> ShieldState
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ShieldState
impl Debug for ShieldState
Source§impl PartialEq for ShieldState
impl PartialEq for ShieldState
impl Copy for ShieldState
impl StructuralPartialEq for ShieldState
Auto Trait Implementations§
impl Freeze for ShieldState
impl RefUnwindSafe for ShieldState
impl Send for ShieldState
impl Sync for ShieldState
impl Unpin for ShieldState
impl UnwindSafe for ShieldState
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