Camera Rotation

Hello guys!

I’ve documented a little about Camera Rotation and I still didn’t found sth to give an effect of Earth Rotation around Sun ( To move the camera around Left Click of mouse which is a static point ).

I founded that I should use cos & sin functions but I don’t know how.

I want to make the rotation like in this 1 but I have 0 ideas how.

Can you help me somehow please?

I would recommend you “child” the camera object, to an otherwise empty object, that is placed at the same location as the SUN object.
Now, you can simply rotate this object, to have the camera rotate about the central point.
e.g.

parentObject.transform.rotation = Quaternion.Euler(0,rotationAngle,0); //sin and cos trig-stuff done in here

Whats nice about using a parent like this is that if the cemera starts out looking at the central object, it will continue to look at the central object, as you rotate the parent.