Rotate camera around object?

hi, i need help with this, how can i rotate the camera around an object? like this :http://www.youtube.com/watch?v=K5toQqcxcNc as you see, the player rotate the camera arround the ship, can somebody tell me how can i do it?

I totally got this. First, parent an empty to the object in question (You know, so that it follows it around and all). Then parent the camera to the empty (so the camera is the child of the empty which is the child of the object). Then, have the empty rotate in the way that you want and vaula, Success!

1 Like

I think we need a bit of clarification. Do you mean at about 25 seconds, when the camera is moved around inside the cabin? Or do you mean a bit later when the camera is outside the ship?

P.S. Literais: What is the point of having the empty control the camera, when you could just control the camera directly?

but i want rotate it with the mouse like on the video

when is outside the ship, and the player rotate it

Well, you should be able to do a track to actuator on the camera, so the camera always points to the object. You can then use regular motion actuators on the camera. Don’t use any rotation in the actuators. The camera will then look at the ship, but the player can move it. It shouldn’t be hard.

but he rotate with the right mouse button (i think) and rotate it like with a mouse look but tracking the ship :spin:

I’m guessing you don’t know Python?

If you knew a little, you could modify a mouselook script pretty easily so it controls movement instead of rotation. And also have the track-to actuator still.

i would try to change the mouselook sript to see wath i can do…:smiley:

Checkout the MouseOrbiter maybe this is what you want.

wow thanks!, But i need it rotates in the Z axis, can you fix that?

The Z-Axis is upward. It uses the Z-axis by default.
You can rotate the pivot object to get the orientation you want. The MouseOrbiter.base will get the same orientation as the pivot.

oh so that hehe, well that was what i need! thanks!:D:D:D

Well, that comment about parenting an “empty” was helpful for me… I don’t know what an empty object is, but I just created a cube inside my subject and parented the camera to it. Previously, I had set up some rotation actions on my subject for this animation of a Small Stellated Dodecahedron http://www.vimeo.com/19377515, but I found that I was not able to easily copy the effects to other objects because each object would start out at a different xyz rotation point, so this should help me considerably in making more CGI SpaceCrafts.

An empty is an GameObject without a mesh. That means it is a pure GameObject without additional functions (like armatures).

You an create it by the add Menu (2.4: <space>/Add/Empty ; 2.5: <ctrl+a>/Empty).

The way mentioned here is to create an empty, setup DoupliGroup which let a group instance appear. If you add via Add/Group (instance) you get the empty with the DoupliGroup in one step.
Be aware that the empty and the group instance are not parented (without further action)!

I hope it helps

refer to this:https://www.youtube.com/watch?v=z6HtJfLoNZc