Browse Source

A few more fixes after some testing

pull/290/head
Jrius 3 years ago
parent
commit
bceadbf784
  1. 3
      korman/exporter/camera.py
  2. 2
      korman/exporter/physics.py
  3. 4
      korman/properties/modifiers/gui.py

3
korman/exporter/camera.py

@ -204,7 +204,8 @@ class CameraConverter:
# path object, but it makes more sense to me to just animate the camera with
# the details of the path...
pos_fcurves = tuple(i for i in helpers.fetch_fcurves(bo, False) if i.data_path == "location")
pos_ctrl = self._exporter().animation.convert_transform_controller(pos_fcurves, bo.rotation_mode, bo.matrix_basis)
pos_ctrl = self._exporter().animation.convert_transform_controller(pos_fcurves, bo.rotation_mode,
bo.matrix_local, bo.matrix_parent_inverse)
if pos_ctrl is None:
raise ExportError("'{}': Rail Camera lacks appropriate rail keyframes".format(bo.name))
path = plAnimPath()

2
korman/exporter/physics.py

@ -93,7 +93,7 @@ class PhysicsConverter:
if so.sim is None:
simIface = self._mgr.add_object(pl=plSimulationInterface, bl=bo)
physical = self._mgr.add_object(pl=plGenericPhysical, bl=bo, name=name)
physical = self._mgr.add_object(pl=plGenericPhysical, bl=bo, name=bo.name)
simIface.physical = physical.key
physical.object = so.key

4
korman/properties/modifiers/gui.py

@ -466,8 +466,8 @@ class PlasmaLinkingBookModifier(PlasmaModifierProperties, PlasmaModifierLogicWiz
if self.clickable_region is None:
with utils.bmesh_object("{}_LinkingBook_ClkRgn".format(self.key_name)) as (rgn_obj, bm):
bmesh.ops.create_cube(bm, size=(6.0))
rgn_offset = mathutils.Matrix.Translation(self.clickable.matrix_world.translation - bo.matrix_world.translation)
bmesh.ops.transform(bm, matrix=rgn_offset, space=bo.matrix_world, verts=bm.verts)
rgn_offset = mathutils.Matrix.Translation(self.clickable.matrix_world.translation - rgn_obj.matrix_world.translation)
bmesh.ops.transform(bm, matrix=rgn_offset, space=rgn_obj.matrix_world, verts=bm.verts)
rgn_obj.plasma_object.enabled = True
rgn_obj.hide_render = True
yield rgn_obj

Loading…
Cancel
Save