Closed Maenzgi closed 3 years ago
I understood it like this: y-component of the velocity is negative so that means the ball is moving downwards. we ignore the if statement if the ball is moving upwards because "we already took care of the collision" and ignore the if statement in the next step(s).
Hi Manuel,
I guess you mean the criteria over the linear velocity. This is from the fact that we cannot prevent the penetration error to certain level with the impulse-based collision paradigm. Thus, we slightly "relax" the constraint: although there might be a penetration, we only detect collision if there's non-zero penetration error as well as the ball is moving downward.
Ahhh ok I missread the "and" statement. I thought collision happensonce either criteria is fullfilled. Sorry about that! And thank you!
Dear TAs
In the code in Ex.4, you say " - detect collision if 1) the y coordinate of the point at the bottom of the sphere < 0 and 2) the y component of linear velocity of the point at the botton < 0." I get the first statement, but why would you apply collision if the y component is smaller zero? Are you refering to the y component in the global frame or in rb frame? I don't understand why this is a criteria.
Best, Manuel