• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
Question by arctic_waffle · Mar 13, 2012 at 02:55 AM · cameraquaternionorbitwasd

Third Person Camera Orbit

I am making a 3D platformer, and trying to use a script that, when the player presses W,A,S,or D, rotates the camera around the player. My friend tried to explain it to me, but I still do not get it. He said something about vectors and quaternions. How does camera orbiting work? What do Vectors and Quaternions do? The WASD controls act the same as they do in cames that use the C stick or the D pad for camera rotation. I need help.

Comment
JustinTheSwift

People who like this

1 Show 5
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image syclamoth · Mar 13, 2012 at 02:56 AM 0
Share

Get your friend to teach you how to code. It's much, much easier to be taught by someone in person than to ask for help on the internet.

avatar image arctic_waffle · Mar 14, 2012 at 02:09 AM 0
Share

My friend has helped me he did it right in front of my eyes. I need a written explination of a Vectors and Quaternions. I need an explination of camera orbiting.

avatar image syclamoth · Mar 14, 2012 at 02:12 AM 0
Share

Almost all of these things are in the script reference and Wikipedia. The resources exist, you just need to look at them.

Camera orbitting works the way you tell it to. There are several ways of implementing it, and the exact details depend entirely on which way you choose to use.

avatar image arctic_waffle · Mar 15, 2012 at 03:24 AM 0
Share

I will go to the Wikipedia page and see if I can find it out. My friend told me it is difficult to understand.

avatar image syclamoth · Mar 15, 2012 at 03:36 AM 0
Share

Friends who tell you you're stupid aren't very good friends. Although, to be fair you don't really need to know how quaternions work to be able to use them, just read up in the script reference to see what you can do. All you really need to know is that they represent rotations in such a way as to avoid gimbal-lock etc, and that they don't translate very well into 3-axis rotations (for exactly that reason). Vectors aren't that hard to understand- they're really just directions in n-dimensional space. You use them every day, and you probably don't even notice.

Other than that, read some coding tutorials, and then actually read through the script to pick it apart. Something like a keyboard orbitter won't be that hard to reverse-engineer, and you'll almost certainly learn something useful.

0 Replies

  • Sort: 

Unity Answers is in Read-Only mode

Unity Answers content will be migrated to a new Community platform and we are aiming to launch a public beta by June 9. Please note, Unity Answers is now in read-only so we can prepare for the final data migration.

For more information and updates, please read our full announcement thread in the Unity Forum.

Follow this Question

Answers Answers and Comments

6 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

orbit mouse camera animation movement script 1 Answer

Free Camera 2 Answers

First Person Camera problem 1 Answer

Camera Help! 1 Answer

Camera Auto-Align with the nearest object with a determinated tag 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges