i have an empty with 4 directions
and i need make empty position follow the ball pivot in Axes X,Y,Z
but no rotation
Vector3 vec_shooting_bola = new Vector3(ball.rigidbody.velocity.x, ball.rigidbody.velocity.y, ball.rigidbody.velocity.z);
empty_shootingBall.position = ball.position;
I take it your solution isn’t working? Have you tried parenting the empty to the object?
You should be able to use that and set it’s rotation to 0 through a script. If that’s not what you need let me know.
Instead of taking the position of the transform of the ball
I took the position of the bone of the ball, it armature
then following this perfectly now
this should do the trick.
Vector3 offset = new Vector3 (0,2f,0);
float step = walkSpeed * Time.deltaTime;
transform.position = Vector3.MoveTowards(transform.position, target.transform.position+ offset, step);