diff options
| author | Sébastien Crozet <developer@crozet.re> | 2022-08-09 09:26:12 +0200 |
|---|---|---|
| committer | Sébastien Crozet <developer@crozet.re> | 2022-08-09 09:26:12 +0200 |
| commit | a19c6131ff63860aa87f320e3e3770ef4e6f4774 (patch) | |
| tree | ead153633d5622605c809c440d1dc8c8f8923dca /src/dynamics | |
| parent | ebb9473491858a4621dae7dd2f768fad49ad0ef2 (diff) | |
| download | rapier-a19c6131ff63860aa87f320e3e3770ef4e6f4774.tar.gz rapier-a19c6131ff63860aa87f320e3e3770ef4e6f4774.tar.bz2 rapier-a19c6131ff63860aa87f320e3e3770ef4e6f4774.zip | |
Make Collider::set_rotation and RigidBody::set_rotation take a rotation instead of an axis-angle.
Diffstat (limited to 'src/dynamics')
| -rw-r--r-- | src/dynamics/rigid_body.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/dynamics/rigid_body.rs b/src/dynamics/rigid_body.rs index 9fa05a6..f03a4b6 100644 --- a/src/dynamics/rigid_body.rs +++ b/src/dynamics/rigid_body.rs @@ -681,9 +681,7 @@ impl RigidBody { /// Sets the rotational part of this rigid-body's position. #[inline] - pub fn set_rotation(&mut self, rotation: AngVector<Real>, wake_up: bool) { - let rotation = Rotation::new(rotation); - + pub fn set_rotation(&mut self, rotation: Rotation<Real>, wake_up: bool) { if self.pos.position.rotation != rotation || self.pos.next_position.rotation != rotation { self.changes.insert(RigidBodyChanges::POSITION); self.pos.position.rotation = rotation; |
