diff options
Diffstat (limited to 'source/blender/editors/object/object_modifier.c')
-rw-r--r-- | source/blender/editors/object/object_modifier.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c index cf3e04b84b8..be69d4ca9ea 100644 --- a/source/blender/editors/object/object_modifier.c +++ b/source/blender/editors/object/object_modifier.c @@ -1804,9 +1804,15 @@ static int skin_armature_create_exec(bContext *C, wmOperator *op) Main *bmain = CTX_data_main(C); Scene *scene = CTX_data_scene(C); Object *ob = CTX_data_active_object(C), *arm_ob; + Mesh *me = ob->data; ModifierData *skin_md; ArmatureModifierData *arm_md; + if (!CustomData_has_layer(&me->vdata, CD_MVERT_SKIN)) { + BKE_reportf(op->reports, RPT_WARNING, "Mesh '%s' has no skin vertex data", me->id.name + 2); + return OPERATOR_CANCELLED; + } + /* create new armature */ arm_ob = modifier_skin_armature_create(scene, ob); |