Skip to content

Commit

Permalink
chore: misc typo fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
sebcrozet committed May 5, 2024
1 parent d0866d4 commit 425b2fc
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 12 deletions.
2 changes: 1 addition & 1 deletion src/control/character_controller.rs
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ pub struct KinematicCharacterController {
/// Increase this number if your character appears to get stuck when sliding against surfaces.
///
/// This is a small distance applied to the movement toward the contact normals of shapes hit
/// by the character controller. This helps shape-casting not getting stuck in an alway-penetrating
/// by the character controller. This helps shape-casting not getting stuck in an always-penetrating
/// state during the sliding calculation.
///
/// This value should remain fairly small since it can introduce artificial "bumps" when sliding
Expand Down
8 changes: 4 additions & 4 deletions src/dynamics/integration_parameters.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ pub struct IntegrationParameters {
/// (default `1.0`).
pub warmstart_coefficient: Real,

/// The approximate size of most dynamic objects in the scale.
/// The approximate size of most dynamic objects in the scene.
///
/// This value is used internally to estimate some length-based tolerance. In particular, the
/// values [`IntegrationParametres::allowed_linear_error`],
/// [`IntegrationParametres::max_penetration_correction`],
/// [`IntegrationParametres::prediction_distance`], [`RigidBodyActivation::linear_threshold`]
/// values [`IntegrationParameters::allowed_linear_error`],
/// [`IntegrationParameters::max_penetration_correction`],
/// [`IntegrationParameters::prediction_distance`], [`RigidBodyActivation::linear_threshold`]
/// are scaled by this value implicitly.
///
/// This value can be understood as the number of units-per-meter in your physical world compared
Expand Down
18 changes: 11 additions & 7 deletions src/geometry/collider.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,16 @@ impl Collider {
self.flags.active_collision_types = active_collision_types;
}

/// The collision skin of this collider.
/// The contact skin of this collider.
///
/// See the documentation of [`ColliderBuilder::contact_skin`] for details.
pub fn contact_skin(&self) -> Real {
self.contact_skin
}

/// Sets the collision skin of this collider.
/// Sets the contact skin of this collider.
///
/// See the documentation of [`ColliderBuilder::contact_skin`] for details.
pub fn set_contact_skin(&mut self, skin_thickness: Real) {
self.contact_skin = skin_thickness;
}
Expand Down Expand Up @@ -451,7 +455,7 @@ impl Collider {

/// Compute the axis-aligned bounding box of this collider.
///
/// This AABB doesn’t take into account the collider’s collision skin.
/// This AABB doesn’t take into account the collider’s contact skin.
/// [`Collider::contact_skin`].
pub fn compute_aabb(&self) -> Aabb {
self.shape.compute_aabb(&self.pos)
Expand Down Expand Up @@ -519,7 +523,7 @@ pub struct ColliderBuilder {
pub enabled: bool,
/// The total force magnitude beyond which a contact force event can be emitted.
pub contact_force_event_threshold: Real,
/// An extract thickness around the collider shape to keep them further apart when in collision.
/// An extra thickness around the collider shape to keep them further apart when colliding.
pub contact_skin: Real,
}

Expand Down Expand Up @@ -973,12 +977,12 @@ impl ColliderBuilder {
self
}

/// Sets the collision skin of the collider.
/// Sets the contact skin of the collider.
///
/// The collision skin acts as if the collider was enlarged with a skin of width `skin_thickness`
/// The contact skin acts as if the collider was enlarged with a skin of width `skin_thickness`
/// around it, keeping objects further apart when colliding.
///
/// A non-zero collision skin can increase performance, and in some cases, stability. However
/// A non-zero contact skin can increase performance, and in some cases, stability. However
/// it creates a small gap between colliding object (equal to the sum of their skin). If the
/// skin is sufficiently small, this might not be visually significant or can be hidden by the
/// rendering assets.
Expand Down

0 comments on commit 425b2fc

Please sign in to comment.