aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSébastien Crozet <developer@crozet.re>2022-07-08 17:21:12 +0200
committerGitHub <noreply@github.com>2022-07-08 17:21:12 +0200
commit6bef5e4352b849e9d32be73ee3601f1aa82a6753 (patch)
tree4cf4f9bb9d860fff0a1bf153012334311ea38b9d /src
parent30f6dc47ec93e497f42d1c7363c75503e15b531c (diff)
parent4025f6231424a2dd2c8a4fca62a77232bbe20807 (diff)
downloadrapier-6bef5e4352b849e9d32be73ee3601f1aa82a6753.tar.gz
rapier-6bef5e4352b849e9d32be73ee3601f1aa82a6753.tar.bz2
rapier-6bef5e4352b849e9d32be73ee3601f1aa82a6753.zip
Merge pull request #364 from dimforge/allowed-translation-rename
Rename allowed_translation/rotation to enabled_translation/rotation
Diffstat (limited to 'src')
-rw-r--r--src/dynamics/rigid_body.rs26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/dynamics/rigid_body.rs b/src/dynamics/rigid_body.rs
index b75035c..9fa05a6 100644
--- a/src/dynamics/rigid_body.rs
+++ b/src/dynamics/rigid_body.rs
@@ -167,7 +167,7 @@ impl RigidBody {
#[inline]
/// Locks or unlocks rotations of this rigid-body along each cartesian axes.
- pub fn set_allowed_rotations(
+ pub fn set_enabled_rotations(
&mut self,
allow_rotations_x: bool,
allow_rotations_y: bool,
@@ -196,7 +196,7 @@ impl RigidBody {
}
/// Locks or unlocks rotations of this rigid-body along each cartesian axes.
- #[deprecated(note = "Use `set_allowed_rotations` instead")]
+ #[deprecated(note = "Use `set_enabled_rotations` instead")]
pub fn restrict_rotations(
&mut self,
allow_rotations_x: bool,
@@ -204,7 +204,7 @@ impl RigidBody {
allow_rotations_z: bool,
wake_up: bool,
) {
- self.set_allowed_rotations(
+ self.set_enabled_rotations(
allow_rotations_x,
allow_rotations_y,
allow_rotations_z,
@@ -229,7 +229,7 @@ impl RigidBody {
#[inline]
/// Locks or unlocks rotations of this rigid-body along each cartesian axes.
- pub fn set_allowed_translations(
+ pub fn set_enabled_translations(
&mut self,
allow_translation_x: bool,
allow_translation_y: bool,
@@ -270,7 +270,7 @@ impl RigidBody {
}
#[inline]
- #[deprecated(note = "Use `set_allowed_translations` instead")]
+ #[deprecated(note = "Use `set_enabled_translations` instead")]
/// Locks or unlocks rotations of this rigid-body along each cartesian axes.
pub fn restrict_translations(
&mut self,
@@ -279,7 +279,7 @@ impl RigidBody {
#[cfg(feature = "dim3")] allow_translation_z: bool,
wake_up: bool,
) {
- self.set_allowed_translations(
+ self.set_enabled_translations(
allow_translation_x,
allow_translation_y,
#[cfg(feature = "dim3")]
@@ -339,7 +339,7 @@ impl RigidBody {
/// a velocity greater than an automatically-computed threshold.
///
/// This is not the same as `self.is_ccd_enabled` which only
- /// checks if CCD is allowed to run for this rigid-body or if
+ /// checks if CCD is enabled to run for this rigid-body or if
/// it is completely disabled (independently from its velocity).
pub fn is_ccd_active(&self) -> bool {
self.ccd.ccd_active
@@ -1104,7 +1104,7 @@ impl RigidBodyBuilder {
}
/// Only allow translations of this rigid-body around specific coordinate axes.
- pub fn allowed_translations(
+ pub fn enabled_translations(
mut self,
allow_translations_x: bool,
allow_translations_y: bool,
@@ -1120,7 +1120,7 @@ impl RigidBodyBuilder {
self
}
- #[deprecated(note = "Use `allowed_translations` instead")]
+ #[deprecated(note = "Use `enabled_translations` instead")]
/// Only allow translations of this rigid-body around specific coordinate axes.
pub fn restrict_translations(
self,
@@ -1128,7 +1128,7 @@ impl RigidBodyBuilder {
allow_translations_y: bool,
#[cfg(feature = "dim3")] allow_translations_z: bool,
) -> Self {
- self.allowed_translations(
+ self.enabled_translations(
allow_translations_x,
allow_translations_y,
#[cfg(feature = "dim3")]
@@ -1146,7 +1146,7 @@ impl RigidBodyBuilder {
/// Only allow rotations of this rigid-body around specific coordinate axes.
#[cfg(feature = "dim3")]
- pub fn allowed_rotations(
+ pub fn enabled_rotations(
mut self,
allow_rotations_x: bool,
allow_rotations_y: bool,
@@ -1162,7 +1162,7 @@ impl RigidBodyBuilder {
}
/// Locks or unlocks rotations of this rigid-body along each cartesian axes.
- #[deprecated(note = "Use `allowed_rotations` instead")]
+ #[deprecated(note = "Use `enabled_rotations` instead")]
#[cfg(feature = "dim3")]
pub fn restrict_rotations(
self,
@@ -1170,7 +1170,7 @@ impl RigidBodyBuilder {
allow_rotations_y: bool,
allow_rotations_z: bool,
) -> Self {
- self.allowed_rotations(allow_rotations_x, allow_rotations_y, allow_rotations_z)
+ self.enabled_rotations(allow_rotations_x, allow_rotations_y, allow_rotations_z)
}
/// Sets the damping factor for the linear part of the rigid-body motion.