Hello!
That’s a lot of code, however, I’m not sure you’ve looked into RICOCHET. According to the video, there’s a component for it. It couullddd remove a lot of unnecessary math.