Question by 
               unity_FyPKcv4aN7qDIA · Sep 30, 2020 at 03:08 AM · 
                c#billboardinghealth  
              
 
              need help with billboarding
hi! i recently looked up a tutorial because i wanted an object to look at the camera as the player moves around. i used what i saw in the tutorial, but it doesn't work?
here's what i have written:
 public class cameraBillboard : MonoBehaviour
 {
     private void Update()
     {
         transform.LookAt(Camera.main.transform.position, -Vector3.up);
     }
 }
 
and here's the error it gives me:
[21:39:04] NullReferenceException: Object reference not set to an instance of an object cameraBillboard.LateUpdate () (at Assets/cameraBillboard.cs:9)
               Comment
              
 
               
              Your answer
 
 
              koobas.hobune.stream
koobas.hobune.stream 
                       
               
 
			 
                