Skip to content

Commit

Permalink
Merge pull request godotengine#369 from Williangalvani/parentisnone
Browse files Browse the repository at this point in the history
Check if object has parent instead of checking if parent is None
  • Loading branch information
Calinou committed Oct 13, 2020
2 parents 83e6475 + a14114c commit 85ab766
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 85ab766

Please sign in to comment.