Rotate camera along one axis

hello can in orbital control script can we make the camera rotate only along one axis?
I’m looking to achieve something like this

also is the camera rotating here or is it the environment?

Original Post on Discord

by user 546555823451668481

You can always make a copy of the OrbitControls script and modify as you see fit.
I think for something like Joshua’s World you want a LookAt target that’s locked to the center (can’t pan) and add some limits to x and y

Both could be (world rotates and camera rotates) :slightly_smiling_face: would recommend doing whatever feels easier for your usecase.

My guess would be that this is rotating the camera though

Yep it’s rotating the camera with regular OrbitControls :slightly_smiling_face:
image.png

where can i find the orbital control TS script?

by user 546555823451668481