Merge branch 'master' into blender2.8
[blender.git] / source / blender / editors / object / object_edit.c
index 2723198b27974b0759ac60bd6bdabefacefb5486..c5f55b138a6f1846e52a9058a51be9839fe074bd 100644 (file)
@@ -1197,7 +1197,7 @@ static int forcefield_toggle_exec(bContext *C, wmOperator *UNUSED(op))
        Object *ob = CTX_data_active_object(C);
 
        if (ob->pd == NULL)
-               ob->pd = object_add_collision_fields(PFIELD_FORCE);
+               ob->pd = BKE_partdeflect_new(PFIELD_FORCE);
        else if (ob->pd->forcefield == 0)
                ob->pd->forcefield = PFIELD_FORCE;
        else