Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • 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
2
Question by Jim 6 · Jan 15, 2011 at 11:45 AM · directionthird-person-controller

Third person controller script - model facing wrong way.

Hi,

I've a character model imported from Max and have applied the Third Person Controller script to it.

All is well with the actual movement of the model on the arrow keys, but the directions that the character model faces are incorrect:

Up key: model faces right

Down key: model faces left

Left key: model faces forward

Right key: model faces backward

Does anybody know how to resolve this, and also why it might have happened in the first place?

Many thanks.

Comment
Add comment · Show 1
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 Jim 6 · Jan 15, 2011 at 11:47 AM 0
Share

Perhaps worth noting that I have the spring follow camera script on the main camera too, set behind the model.

2 Replies

· Add your reply
  • Sort: 
avatar image
2

Answer by Peter G · Jan 15, 2011 at 12:27 PM

This is a common problem. Create an empty GameObject, make your model a child of it, rotate the model so that it is orientated correctly. Attach the controller script to the (used to be) empty Game Object and move that instead.

Comment
Add comment · Show 1 · Share
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 Jim 6 · Jan 15, 2011 at 02:07 PM 0
Share

Thanks, this has helped to get it looking correct.

$$anonymous$$y next question...given that my character model is now the child of the empty GameObject, where would I put the Third Person Player animation script?

It seems that this has to be in the same place as the controller script, but the animations are on the character model, not the gameObject.

If there's a way I can get this right without having the model in the empty gameObject I'd be very interested in knowing..

Cheers

avatar image
0

Answer by Jim 6 · Jan 15, 2011 at 02:42 PM

Ok, I figured it out.

I grouped my mesh and biped in Max, rotated them so that the Z axis points up, the Y axis extends out the back of the character and the X axis points down the right arm (facing you).

I then ungrouped them and exprted as a .FBX file keeping Z-up in the export options.

This seems to have eliminated the need to parent the model to an empty gameObject and rotate it inside.

Comment
Add comment · Show 1 · Share
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 PrimeDerektive · Jan 15, 2011 at 02:55 PM 1
Share

Sometimes when this happens with models I've purchased (I'm not a 3d artist) ins$$anonymous$$d of parenting it to an empty gameobject I just set the Z scale of the transform to -1 and it usually does the trick. But yeah, for some reason Unity has the z-axis backwards.

Your answer

Hint: You can notify a user about this post by typing @username

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

Answers Answers and Comments

1 Person is following this question.

avatar image

Related Questions

Physics2D AddForce Direction Vector Issue 1 Answer

Raycast between TransformDirection and Vector3.Forward? 1 Answer

Change characters direction using camera view 0 Answers

Model is facing the wrong way 1 Answer

Weird angle returned 1 Answer


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