Fix for bug #10475: added more dependencies for physics systems

with deflectors and fields for proper dependency graph updates.
This commit is contained in:
2008-05-09 13:04:36 +00:00
parent 6a97a2ab33
commit 7e93f5569d
2 changed files with 24 additions and 16 deletions

View File

@@ -3208,6 +3208,7 @@ static void object_collision__enabletoggle ( void *ob_v, void *arg2 )
{
md = modifier_new ( eModifierType_Collision );
BLI_addtail ( &ob->modifiers, md );
DAG_scene_sort(G.scene);
DAG_object_flush_update(G.scene, ob, OB_RECALC_DATA);
allqueue(REDRAWBUTSEDIT, 0);
allqueue(REDRAWVIEW3D, 0);
@@ -3215,8 +3216,10 @@ static void object_collision__enabletoggle ( void *ob_v, void *arg2 )
}
else
{
DAG_object_flush_update(G.scene, ob, OB_RECALC_DATA);
BLI_remlink ( &ob->modifiers, md );
modifier_free ( md );
DAG_scene_sort(G.scene);
allqueue(REDRAWBUTSEDIT, 0);
}
}