Calculate Forward Axis

How do you calculate which axis is forward on a gameObject? I just want a raycast to start in front of an object.

You can just use transform.forward

Sorry, my bad I am using line cast and it hits the collider that is doing the cast so I wanted to cast starting one in front of it so it wont hit.

So do transform.position + transform.forward. That’ll give you a vector 1 unit in front of the object.

Thank you!