Skip to content

Commit

Permalink
Closes #536, #538
Browse files Browse the repository at this point in the history
  • Loading branch information
tngreene committed Mar 7, 2020
1 parent ed97915 commit d236324
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion io_xplane2blender/xplane_types/xplane_commands.py
Expand Up @@ -133,7 +133,7 @@ def writeXPlaneBone(self, xplaneBone:xplane_bone.XPlaneBone, lod_bucket_index:Op
xplaneObject = xplaneBone.xplaneObject
xplaneObjectWritten = False

if xplaneObject:
if xplaneObject and not xplaneObject.export_animation_only:
if lod_bucket_index is None:
o += self._writeXPlaneObjectPrefix(xplaneObject)
xplaneObjectWritten = True
Expand Down
5 changes: 4 additions & 1 deletion io_xplane2blender/xplane_types/xplane_file.py
Expand Up @@ -289,9 +289,12 @@ def recurse(parent: Optional[bpy.types.Object], parent_bone: Optional[XPlaneBone
pass

if new_xplane_obj:
# If set from walking up, keep that. Otherwise, decide based on visiblity
new_xplane_obj.export_animation_only = new_xplane_obj.export_animation_only or not blender_obj.visible_get()
# This is different than asking the Blender Light its type!
# This is refering to the old style default light
if isinstance(new_xplane_obj, XPlaneLight):
if (isinstance(new_xplane_obj, XPlaneLight)
and not new_xplane_obj.export_animation_only):
self.lights.append(new_xplane_obj)
new_xplane_obj.collect()
elif blender_obj:
Expand Down

0 comments on commit d236324

Please sign in to comment.