Skip to content

Commit

Permalink
Check if object has parent instead of checking if parent is None
Browse files Browse the repository at this point in the history
  • Loading branch information
Williangalvani committed Oct 13, 2020
1 parent 564aa4f commit a14114c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion io_scene_godot/export_godot.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def export_object(self, obj, parent_gd_node):
# CollisionShape node has different direction in blender
# and godot, so it has a -90 rotation around X axis,
# here rotate its children back
if (exported_node.parent is not None and
if (hasattr(exported_node, "parent") and
exported_node.parent.get_type() == 'CollisionShape'):
exported_node['transform'] = (
_AXIS_CORRECT.inverted() @
Expand Down

0 comments on commit a14114c

Please sign in to comment.