pub enum ImpulseModel {
PerBody(f32),
Total(f32),
}Expand description
Scalar impulse policy; magnitudes must be finite and nonnegative.
Variants§
PerBody(f32)
Each body receives magnitude * falloff_weight impulse units.
Total(f32)
Split this total scalar impulse budget in proportion to falloff weights. This bounds the sum of magnitudes, not the vector sum or kinetic energy. With no eligible nonzero weights, no impulse is spent. f32 rounding applies.
Trait Implementations§
Source§impl Clone for ImpulseModel
impl Clone for ImpulseModel
Source§fn clone(&self) -> ImpulseModel
fn clone(&self) -> ImpulseModel
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 ImpulseModel
impl Debug for ImpulseModel
Source§impl PartialEq for ImpulseModel
impl PartialEq for ImpulseModel
impl Copy for ImpulseModel
impl StructuralPartialEq for ImpulseModel
Auto Trait Implementations§
impl Freeze for ImpulseModel
impl RefUnwindSafe for ImpulseModel
impl Send for ImpulseModel
impl Sync for ImpulseModel
impl Unpin for ImpulseModel
impl UnwindSafe for ImpulseModel
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