Skip to content

Commit

Permalink
Fix #2271 Avoid crash with skinned lattices
Browse files Browse the repository at this point in the history
  • Loading branch information
julienduroure committed Jun 21, 2024
1 parent b6fe881 commit d9aca3f
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -470,6 +470,12 @@ def gather_skin(vnode, export_settings):
return None

blender_object = export_settings['vtree'].nodes[vnode].blender_object

# Lattice can have armature modifiers & vertex groups, but we don't want to export them
# Avoid crash getting mesh data from lattices
if blender_object and blender_object.type == 'LATTICE':
return None

modifiers = {m.type: m for m in blender_object.modifiers} if blender_object else {}
if "ARMATURE" not in modifiers or modifiers["ARMATURE"].object is None:
return None
Expand Down

0 comments on commit d9aca3f

Please sign in to comment.