forked from bartvdbraak/blender
fix: leave default behaviour the same to be backward compatible with previous rigid body constraints: No Collision between linked objects if button is pressed.
This commit is contained in:
parent
3c27b8034b
commit
7995395fd2
@ -1508,7 +1508,7 @@ static void draw_constraint (uiBlock *block, ListBase *list, bConstraint *con, s
|
||||
uiDefButI(block, MENU, B_CONSTRAINT_TEST, "Joint Types%t|Ball%x1|Hinge%x2|Cone Twist%x4|Generic (experimental)%x12",//|Extra Force%x6",
|
||||
*xco, *yco-25, 150, 18, &data->type, 0, 0, 0, 0, "Choose the joint type");
|
||||
|
||||
uiDefButBitS(block, TOG, CONSTRAINT_DISABLE_LINKED_COLLISION, B_CONSTRAINT_TEST, "Collision", *xco+155, *yco-25, 111, 18, &data->flag, 0, 24, 0, 0, "Enable Collision Between Linked Bodies");
|
||||
uiDefButBitS(block, TOG, CONSTRAINT_DISABLE_LINKED_COLLISION, B_CONSTRAINT_TEST, "No Col.", *xco+155, *yco-25, 111, 18, &data->flag, 0, 24, 0, 0, "Disable Collision Between Linked Bodies");
|
||||
|
||||
|
||||
uiDefIDPoinBut(block, test_obpoin_but, ID_OB, B_CONSTRAINT_CHANGETARGET, "toObject:", *xco, *yco-50, 130, 18, &data->tar, "Child Object");
|
||||
|
@ -887,7 +887,7 @@ int CcdPhysicsEnvironment::createUniversalD6Constraint(
|
||||
)
|
||||
{
|
||||
|
||||
bool disableCollisionBetweenLinkedBodies = (0==(flags & CCD_CONSTRAINT_DISABLE_LINKED_COLLISION));
|
||||
bool disableCollisionBetweenLinkedBodies = (0!=(flags & CCD_CONSTRAINT_DISABLE_LINKED_COLLISION));
|
||||
|
||||
//we could either add some logic to recognize ball-socket and hinge, or let that up to the user
|
||||
//perhaps some warning or hint that hinge/ball-socket is more efficient?
|
||||
@ -1496,7 +1496,7 @@ int CcdPhysicsEnvironment::createConstraint(class PHY_IPhysicsController* ctrl
|
||||
)
|
||||
{
|
||||
|
||||
bool disableCollisionBetweenLinkedBodies = (0==(flags & CCD_CONSTRAINT_DISABLE_LINKED_COLLISION));
|
||||
bool disableCollisionBetweenLinkedBodies = (0!=(flags & CCD_CONSTRAINT_DISABLE_LINKED_COLLISION));
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user