Skip to content

Instantly share code, notes, and snippets.

@DataGreed
Created May 22, 2019 00:13
Show Gist options
  • Select an option

  • Save DataGreed/a5ed4d3eb3f2be576a07cf58a0dd7d1b to your computer and use it in GitHub Desktop.

Select an option

Save DataGreed/a5ed4d3eb3f2be576a07cf58a0dd7d1b to your computer and use it in GitHub Desktop.
fix lookAt position
bullet.transform.rotation = Quaternion.Euler( 90, 0, 0 ) * Quaternion.LookAt( target.transform.position - bullet.transform.position ) ;
// OR
//bullet.transform.rotation = Quaternion.LookAt( target.transform.position - bullet.transform.position ) * Quaternion.Euler( 90, 0, 0 ) ;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment