pub struct CollisionInfo<V: VectorSpace> {
pub self_contact: V,
pub other_contact: V,
pub vector: V,
}Expand description
Information of a detected collision between colliders objects. The information is stored as elements of the specified vector space.
Fields§
§self_contact: VThe contact point at the first collider.
other_contact: VThe contact point at the other collider.
vector: VThe smallest vector by which the first collider needs to be moved, so the objects won’t touch each other anymore.
Trait Implementations§
Source§impl<V: Clone + VectorSpace> Clone for CollisionInfo<V>
impl<V: Clone + VectorSpace> Clone for CollisionInfo<V>
Source§fn clone(&self) -> CollisionInfo<V>
fn clone(&self) -> CollisionInfo<V>
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<V: Debug + VectorSpace> Debug for CollisionInfo<V>
impl<V: Debug + VectorSpace> Debug for CollisionInfo<V>
Source§impl<V: VectorSpace> Neg for CollisionInfo<V>
impl<V: VectorSpace> Neg for CollisionInfo<V>
impl<V: Copy + VectorSpace> Copy for CollisionInfo<V>
Auto Trait Implementations§
impl<V> Freeze for CollisionInfo<V>where
V: Freeze,
impl<V> RefUnwindSafe for CollisionInfo<V>where
V: RefUnwindSafe,
impl<V> Send for CollisionInfo<V>where
V: Send,
impl<V> Sync for CollisionInfo<V>where
V: Sync,
impl<V> Unpin for CollisionInfo<V>where
V: Unpin,
impl<V> UnwindSafe for CollisionInfo<V>where
V: UnwindSafe,
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