diff --git a/korman/exporter/convert.py b/korman/exporter/convert.py index afba199..9761eb3 100644 --- a/korman/exporter/convert.py +++ b/korman/exporter/convert.py @@ -245,7 +245,7 @@ class Exporter: ci = self.mgr.add_object(ci_cls, bl=bl, so=so) # Now we have the "fun" work of filling in the CI - ci.localToWorld = utils.matrix44(bl.matrix_basis) + ci.localToWorld = utils.matrix44(bl.matrix_world) ci.worldToLocal = ci.localToWorld.inverse() ci.localToParent = utils.matrix44(bl.matrix_local) ci.parentToLocal = ci.localToParent.inverse() diff --git a/korman/exporter/utils.py b/korman/exporter/utils.py index cdae5b7..75405fd 100644 --- a/korman/exporter/utils.py +++ b/korman/exporter/utils.py @@ -102,8 +102,8 @@ def temporary_mesh_object(source : bpy.types.Object) -> bpy.types.Object: obj = bpy.data.objects.new(source.name, source.to_mesh(bpy.context.scene, True, "RENDER")) obj.draw_type = "WIRE" - obj.matrix_basis, obj.matrix_world = source.matrix_basis, source.matrix_world obj.parent = source.parent + obj.matrix_local, obj.matrix_world = source.matrix_local, source.matrix_world bpy.context.scene.objects.link(obj) try: