I’ve been recently jamming my head against importing .x models to my game by exporting them from Blender, and have decided to go on a tangent and write my own exporter instead. Apologies if this has been asked/answered elsewhere, I searched first and couldn’t come across it. Maybe I’m missing something obvious.
When trying to get a vertex position with ‘bpy.data.meshes.vertices.co’, it returns a Vector object that outputs as:
Vector (-1.0000, - 0.0000, -1.0000)
This is the correct position of the vertex. However, when trying to access that same object’s individual values, they output as the following:
bpy.data.meshes.vertices.co.x = -1.000000238418579
bpy.data.meshes.vertices.co.y = -1.7881393432617188e-07
bpy.data.meshes.vertices.co.z = -1.0
Besides the z value, these are completely wrong. It could be said that the x value is an estimate, but why would it change from the exact value it was showing before? And the y value is just completely wrong as far as I know.
Am I forgetting to transform it by a certain value? This has become very frustrating, especially since the official documentation just says it’s an array of three float values.