How do I prevent players from going threw walls with raycasts?

Ray casting is quite expensive as well because firing one every frame is very performance-heavy. You can put all the walls in one folder called walls and then loop through them to assign a touched connection. I think this is a lil better than raycasting every frame

1 Like