pub struct JointBuilder { /* private fields */ }Expand description
Connections use local anchors relative to each body’s authored origin.
Implementations§
Source§impl JointBuilder
impl JointBuilder
pub fn fixed() -> JointBuilder
pub fn hinge() -> JointBuilder
pub fn distance(length: f32) -> JointBuilder
pub fn spring(length: f32, stiffness: f32, damping: f32) -> JointBuilder
pub fn local_anchor1(self, anchor: Vec2) -> JointBuilder
pub fn local_anchor2(self, anchor: Vec2) -> JointBuilder
pub fn reference_rotation(self, rotation: Rotation2) -> JointBuilder
pub fn limits(self, lower: f32, upper: f32) -> JointBuilder
pub fn motor(self, motor: JointMotor) -> JointBuilder
pub fn contacts_enabled(self, enabled: bool) -> JointBuilder
pub fn build(self) -> JointDesc
Trait Implementations§
Source§impl Clone for JointBuilder
impl Clone for JointBuilder
Source§fn clone(&self) -> JointBuilder
fn clone(&self) -> JointBuilder
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 JointBuilder
impl Debug for JointBuilder
Source§impl From<JointBuilder> for JointDesc
impl From<JointBuilder> for JointDesc
Source§fn from(b: JointBuilder) -> JointDesc
fn from(b: JointBuilder) -> JointDesc
Converts to this type from the input type.
impl Copy for JointBuilder
Auto Trait Implementations§
impl Freeze for JointBuilder
impl RefUnwindSafe for JointBuilder
impl Send for JointBuilder
impl Sync for JointBuilder
impl Unpin for JointBuilder
impl UnwindSafe for JointBuilder
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