As mentioned last week, the goal this time around was to fully get the capsule to capsule collision working. While I have made headway with the system, there are still issues with the system. I was able to properly detect the collision. However, there is an edge case where the collision is not detected when two long/tall capsules positioned near perpendicularly with each other is intersecting about the midpoint of each other. The issue has been noted, but in most situations, this case should not happen. Thus, we have decided to put this on hold until it becomes an absolute necessity to account for this edge case.
Additional to the capsule collision, we have been working to incorporate a spatial partitioning system to optimize the collision checks. Austin was working on the partitioning, while I was working with physics system. Upon first integration, we had originally planned to have the physics system pass in a component to the partition and it would return a list of other components within the same partitioned space. However, we realized that this causes duplicate checks, i.e. component A checks against component B, and component B would also check against component A. Therefore, we have changed the function to return all the components in all the partitioned space and have the physics systems loop through each “bucket” and test the objects inside.
This somewhat eliminated the duplicate issue. However, an edge case still exists where if an object occupies more than one bucket and another object happens to occupy the same multiple buckets, the same two objects will be tested for each bucket that they both occupy since we are testing contents within the buckets. We have noted the issue and will have to decide on a course of action for the following weeks.