- Home /
Question by
tyo8686 · Mar 23, 2012 at 02:16 AM ·
camerameshmouseorbit
Prevent Gameobject/Camera from penetrating another gameobject/mesh
Is there a way to prevent a Camera from penetrating through another object?
I have camera in a scene that has a modified Mouse Orbit Script[default with unity] but using the arrow keys for navigation. It also has a Gameobject [orbit origin] which can be used for forward and backward movement.
The only problem is that I want to put a script or component that prevents them from penetrating other objects in the scene, especially the building[mesh].
Comment
Answer by farooqaaa · Mar 23, 2012 at 03:42 AM
Its a lot of complicated. Check out these video tutorials:
http://www.3dbuzz.com/vbforum/sv_videonav.php?fid=6d5630dac2c391b9e563c4693d44d7cc
It explains it in a very good detail.
nice link, thanks. am about to start watching some vids now :)
Your answer
![](https://koobas.hobune.stream/wayback/20220613065433im_/https://answers.unity.com/themes/thub/images/avi.jpg)