Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import bpy
- # Loop through all currently selected objects
- for obj in bpy.context.selected_objects:
- # Ensure the object is a mesh
- if obj.type == 'MESH':
- # Loop through vertex groups backwards to delete safely
- for vg in reversed(obj.vertex_groups):
- # Check if the group is unlocked
- if not vg.lock_weight:
- # Remove the unlocked group
- obj.vertex_groups.remove(vg)
Advertisement
Add Comment
Please, Sign In to add comment