Fix T81745: Auto Weights fails with Mirror mod + Vertex Groups X

Fix the Assign Automatic Weights operator in weight paint mode when the
Vertex Groups X option is enabled. This issue was probably introduced in
rB5502517c3c12 where `me->editflag & ME_EDIT_MIRROR_X` was replaced by
either `me->editflag & ME_EDIT_VERTEX_GROUPS_X_SYMMETRY` or
`me->symmetry & ME_SYMMETRY_X`. In this case, the former wasn't working,
so I replaced it with the latter.
This commit is contained in:
Sybren A. Stüvel
2020-12-07 16:30:09 +01:00
parent 2e221de4ce
commit c51a70537b

View File

@@ -120,13 +120,8 @@ static int weight_from_bones_exec(bContext *C, wmOperator *op)
Mesh *me = ob->data;
int type = RNA_enum_get(op->ptr, "type");
ED_object_vgroup_calc_from_armature(op->reports,
depsgraph,
scene,
ob,
armob,
type,
(me->editflag & ME_EDIT_VERTEX_GROUPS_X_SYMMETRY));
ED_object_vgroup_calc_from_armature(
op->reports, depsgraph, scene, ob, armob, type, (me->symmetry & ME_SYMMETRY_X));
DEG_id_tag_update(&me->id, 0);
DEG_relations_tag_update(CTX_data_main(C));