Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Pin constraints not breaking in 4.x?
#10
(21-02-2019, 11:04 AM)josemendez Wrote: Hi there,

Just tried it, they're breaking fine for me. Just make sure the breaking threshold is low enough.

Hmm. This is a mystery, then. My breaking thresholds are suitably low (0.1 is what was working before and I've tried .0001 etc).

Delving into the Obi code, at ObiPinConstraintBatch.cs -> BreakConstraints(), I've added a debug line:


Quote:bool torn = false;
for (int i = 0; i < ConstraintCount; i++){

    if (constraintForces[i * 4 + 3] != 0) Debug.Log(constraintForces[i * 4 + 3]);  //debug

    if (-constraintForces[i*4 + 3] * 1000 > pinBreakResistance[i]){ // units are kilonewtons.
        activeConstraints.Remove(i);
        torn = true;
    }
}

and that's never printing to the console, ie., all checked constraintForces indexes are always zero.

I haven't got as far as to figure out where that array is updated, presumably by a Solver.

Also, whereabouts might I be able to check whether I definitely have the changes made in 4.0.2?

Thanks again!

Ric
Reply


Messages In This Thread
RE: Pin constraints not breaking in 4.x? - by autopsyturvey - 21-02-2019, 12:17 PM