- Home /
Question by
saishania · Oct 11, 2011 at 07:38 PM ·
camera movement
camera control-zoom in/out and rotate left and right for a terain
Im new here and can't find a suitable code for the above. It is a 3d city where the user can zoom in and out or rotate left and right. its based on a touch screen.
Comment
Answer by NewfieJoe · Oct 11, 2011 at 08:31 PM
Just change the FOV (Field of View) for the camera. That will give you the effect you're looking for easily for zooming in and out. As far as rotation is concerned. Add an empty object and make the main camera it's child. When you rotate the parent object the camera will rotate around it keeping the same distance.
Answer by saishania · Oct 12, 2011 at 03:31 PM
that is working but how do I set a limit to the camera to zoom in/ out and rotate. It is like setting a boundary for the users to zoom and rotate.
Your answer
![](https://koobas.hobune.stream/wayback/20220613004242im_/https://answers.unity.com/themes/thub/images/avi.jpg)