pub struct ColliderDesc {
pub parent_body: Option<RigidBodyHandle>,
pub position: Vec3,
pub rotation: Quat,
pub shape: ColliderShape,
pub active_events: bool,
pub friction: f32,
pub restitution: f32,
}Expand description
Description for creating a collider.
Fields§
§parent_body: Option<RigidBodyHandle>Parent rigid body to attach to (if any).
position: Vec3Relative or absolute position.
rotation: QuatRelative or absolute rotation.
shape: ColliderShapeShape definition.
active_events: boolWhether to enable collision events for this collider.
friction: f32Friction coefficient.
restitution: f32Restitution (bounciness) coefficient.
Trait Implementations§
Source§impl Clone for ColliderDesc
impl Clone for ColliderDesc
Source§fn clone(&self) -> ColliderDesc
fn clone(&self) -> ColliderDesc
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 ColliderDesc
impl Debug for ColliderDesc
Source§impl<'de> Deserialize<'de> for ColliderDesc
impl<'de> Deserialize<'de> for ColliderDesc
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 ColliderDesc
impl RefUnwindSafe for ColliderDesc
impl Send for ColliderDesc
impl Sync for ColliderDesc
impl Unpin for ColliderDesc
impl UnwindSafe for ColliderDesc
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