pub trait CanCollide {
// Required method
fn collides_with_pos(&self, pos: Vec2D) -> bool;
}Expand description
Must be implemented to be used by the CollisionContainer
Required Methods§
Sourcefn collides_with_pos(&self, pos: Vec2D) -> bool
fn collides_with_pos(&self, pos: Vec2D) -> bool
Returns true if the collider intersects the passed position
Trait Implementations§
Source§impl<'a> From<&'a dyn CanCollide> for CollisionContainer<'a>
impl<'a> From<&'a dyn CanCollide> for CollisionContainer<'a>
Source§fn from(element: &'a dyn CanCollide) -> Self
fn from(element: &'a dyn CanCollide) -> Self
Converts to this type from the input type.