This is a simple and easy to use script for limiting the Camera Movement in Unity3d.
The code is well commented so you can easily read the code and know how it happened.
- Limit the Camera Rotation X from Xmin to Xmax
- Limit the Camera Roration in Y Axis from Ymin to Ymax
- Limit the mouse Sensitivity for rotation X or Y
This script is great and simple for using in menus or somewhere you need to limit the camera rotation but you need to move a little bit when player move the mouse.