I would like to display the distance of the player from the center of a filled map or from map decorations if present.
I have found that the world coordinates of decorations are in the item's tag. However, for banners or maps without decorations, they are not present in the tag.
I found in the MapItemSavedData class the coordinates of the center: "centerX" and "centerZ," which would be perfect for my case. However, this class seems to be updated only on the server side.
How can I determine the absolute coordinates of banners or the map center on the client side?
Thank you very much!