unity how to get gameobject position code example
Example 1: unity get velocity of gameobject
Rigidbody rb = GetComponent<Rigidbody>();
rb.velocity; // Velocity of gameObject (Vector3)
Example 2: get position of gameobject unity
GameObject.FindGameObjectWithTag("Your_Tag_Here").transform.position;