Disable gravity in Draw Face Sets brush

Applying gravity to this brush does not make much sense and undo/redo
won't work correctly as it uses a different undo type.

Reviewed By: sergey

Differential Revision: https://developer.blender.org/D7925
This commit is contained in:
Pablo Dobarro 2020-06-04 00:50:06 +02:00
parent 15ed2f841c
commit f2a0532111
1 changed files with 2 additions and 1 deletions

View File

@ -5486,7 +5486,8 @@ static void do_brush_action(Sculpt *sd, Object *ob, Brush *brush, UnifiedPaintSe
}
/* The cloth brush adds the gravity as a regular force and it is processed in the solver. */
if (ss->cache->supports_gravity && brush->sculpt_tool != SCULPT_TOOL_CLOTH) {
if (ss->cache->supports_gravity &&
!ELEM(brush->sculpt_tool, SCULPT_TOOL_CLOTH, SCULPT_TOOL_DRAW_FACE_SETS)) {
do_gravity(sd, ob, nodes, totnode, sd->gravity_factor);
}