diff --git a/README.md b/README.md index 3038799..f64f368 100644 --- a/README.md +++ b/README.md @@ -245,8 +245,8 @@ That will generate the rom at `/build/portal64.z64` ## Current New Feature TODO List - [ ] test chamber 10 without jumping - [ ] check if display list is long enough -- [ ] check collider flags when filtering contacts - [ ] pausing while glados is speaking can end her speech early +- [x] check collider flags when filtering contacts - [x] gun flicker between levels - [x] fizzler player sound effect - [x] clear z buffer instead of partitioning it diff --git a/src/physics/contact_solver.c b/src/physics/contact_solver.c index 79a9701..bdefaa4 100644 --- a/src/physics/contact_solver.c +++ b/src/physics/contact_solver.c @@ -25,6 +25,11 @@ struct ContactSolver gContactSolver; void contactSolverCleanupManifold(struct ContactManifold* manifold) { int writeIndex = 0; + if (!(manifold->shapeA->collisionLayers & manifold->shapeB->collisionLayers)) { + manifold->contactCount = 0; + return; + } + for (int readIndex = 0; readIndex < manifold->contactCount; ++readIndex) { struct ContactPoint* contactPoint = &manifold->contacts[readIndex]; struct Vector3 offset;