Display the new position of object with Gizmo

Hello I use the gizmo method for moving and scaling object but when i place the object i want display the new position of my object but when i display object.position.x for exemple, this is the old position who was displayed.

Hi @LeoPaulD and welcome to the forum!

I guess you want to display the position while dragging the gizmo?
You can use absolutePosition Mesh | Babylon.js Documentation
Please share a playground if it doesn’t help.

Hi @Cedric
https://playground.babylonjs.com/#31M2AP#191

I want display the new position of this sphere

You have to update the label text otherwise, it will stay with the postion the first time you set its text.
Guizmo + new position | Babylon.js Playground (babylonjs.com)
In this PG, the update is done every frame. You can improve it by updating only when the gizmo is dragged.

1 Like

thank you very much i am still a beginner in js and babylonjs

1 Like