- Home /
Camera collision problem
Hello,
I am using a camera that rotates around an object. However, there is no collision detecting, so it goes trought everything.
What is the best/easiest solution to make the fix this issue?
Comment
Best Answer
Answer by sneftel · Aug 24, 2011 at 04:40 PM
You can cast a ray from the object towards the camera to figure out how far away it is from the closest obstacle, then put the camera closer than that. You'll have to figure out how to handle the situation where the character is right next to a wall, though.