Skip to content

Commit

Permalink
Reword
Browse files Browse the repository at this point in the history
  • Loading branch information
tim-blackbird committed Oct 17, 2022
1 parent 0220db3 commit a266ccf
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions crates/bevy_transform/src/components/transform.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@ impl Transform {
/// local `Z` direction is toward `target` and its unit vector in the local `Y` direction
/// is toward `up`.
///
/// Produces a broken rotation if the resulting forward direction is parralel with `up`.
/// It is not possible to construct a rotation when the resulting forward direction is parallel with `up`.
/// This will result in the [`Transform`] having a broken rotation.
#[inline]
#[must_use]
pub fn looking_at(mut self, target: Vec3, up: Vec3) -> Self {
Expand Down Expand Up @@ -318,7 +319,8 @@ impl Transform {
/// Rotates this [`Transform`] so that its local negative `Z` direction is toward
/// `target` and its local `Y` direction is toward `up`.
///
/// Produces a broken rotation if the resulting forward direction is parralel with `up`.
/// It is not possible to construct a rotation when the resulting forward direction is parallel with `up`.
/// This will result in the [`Transform`] having a broken rotation.
#[inline]
pub fn look_at(&mut self, target: Vec3, up: Vec3) {
let forward = Vec3::normalize(self.translation - target);
Expand Down

0 comments on commit a266ccf

Please sign in to comment.