- Home /
Question by
Jellogramming · Sep 18, 2021 at 07:02 PM ·
rotationdirectiontransform.forward
transform.forward not working correctly?
I am a beginner to using unity, so this is probably a simple mistake. I want to move my player forward in my game, but transform.forward doesn't point forward when the object I put the script on is rotated?
inputY = Input.GetAxisRaw("Vertical") * Time.deltaTime;
if (inputY > 0){
rb.velocity = transform.forward * speed;
}
Comment