x


Basic Camera Movement

I'm new to unity and can't find an explanation of how to move the main camera. I'd just like hit the space bar and move the position and rotation to different preset coordinates (first person, over the shoulder, map etc). I'm so new to Unity that I don't know if this is simple or complex.

Is there a simple way to either animate the camera move or just zap between positions?

Any help would be greatly appreciated.

more ▼

asked May 27 '12 at 09:14 PM

mythraend gravatar image

mythraend
16 2 5 6

(comments are locked)
10|3000 characters needed characters left

1 answer: sort oldest

The Camera object has a Transform component associated with it. Through the Transform component you have the ability to change both the position and rotation of the object. Changing these parameters will result in either a change of location of the camera or a change in its rotation (or both). You can store (perhaps in an array) a set of pre-defined values for location and rotation and then with a space bar press, change to the next one in the list.

I'd strongly suggest reading about the concept of "Transforms" and then think about applying those to your camera. Understanding transforms will give you that "aha" moment to achieve what you want with the camera.

more ▼

answered May 27 '12 at 09:19 PM

kolban gravatar image

kolban
1.8k 2 7

Thanks, kolban. I looked up the Transform component and that got headed in the right direction.

May 27 '12 at 09:48 PM mythraend
(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x2996
x885

asked: May 27 '12 at 09:14 PM

Seen: 423 times

Last Updated: May 27 '12 at 09:48 PM