Hello community,
I’ve a strange behavior of my Ray Casting. I have a huge map which contains houses and walls. When I come close to the edges of for example a wall, my ray casting is wrong. I tried drawing it in Paint… The beginning of the ray is at the star, pink dots are the calculated hit points (which are wrong for the upper 4 rays), and brown are the rays. The other images are screenshots from the game. The pink dots always show the hit location.
Which is even more strange - when I am far away from this edges all ray casts are fine but when I come close, the failed rays look like a triangle at the edges. The returned object is the wall.
Anyone has an idea how to solve it? Every mesh looks fine in its wireframe.
Thanks a lot for reading and hopefully helping!
~L