How to move the player with XROrigin?

I try to move the player with XROrigin, but when I do something with the transform of the XROrigin or CameraOffset, the object itself do move but my vision in the VisionPro stays.So I am wondering how to move the player using transform.

What do you mean by player?

The player means the camera of the scene, also what I see from the device.
I attached such code to the XROrigin to make me move forward automatically:

private void Update()
    {
        transform.position = transform.position + Vector3.forward * Time.deltaTime * 0.1f;
    }

But I failed and this is what I see:



The XROrigin do move forward, but my vision stay.

Are you using Metal mode or RealityKit mode? In RealityKit mode, the way to do this is to move the Volume Camera transform. In Metal mode, you might want to look at how XR Interaction Toolkit handles movement.

So the Volume Camera reference my vision in unbounded mode?

That’s correct; the Volume Camera represents the position/orientation/scale of the viewer. So, if you move it two units forward in Z, the content you see will move two units backwards in Z.