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
1
Question by CuddleMonster · Jan 18, 2013 at 01:04 AM · rotationiphonecharacter controllervehicle

Character Controller for a vehicle?

My intent is to make a basic motorcycle. I am not aiming for realism at all... but it needs to be able to go over jumps... preferably land them fairly smoothly, and should be very consistent. I have found that wheel colliders are TOO realistic.. and make the game too hard to play when they are worried about simply driving without wiping out... as opposed to the other objectives.

My question: is how would I let the bike model rotate so it matches the ground it is on? just attaching a bike to the character controller causes the bike to stay at the same X angle at all times? Hopefully that is clear enough. (diagram done using paint below)

https://www.dropbox.com/s/awwuzjfpmqjslvt/Bikes.png

PS. if it matters... this is targeting iOS

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 cdrandin · Jan 18, 2013 at 01:08 AM 0
Share

Why don't you check out Unity's car tutorial which is very detailed. You can also transfer the info to a motorcycle easily with slight modification. http://u3d.as/content/unity-technologies/car-tutorial/1qU Now you want to jump, which will most likely involve you apply a force upwards by a lot.

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by Eric5h5 · Jan 18, 2013 at 01:42 AM

Even when not aiming for realism, a character controller rarely works well at all for a vehicle. It's really strictly for characters, as the name suggests. You don't need to use wheel colliders, but you should avoid character controllers in this case.

Comment
Add comment · 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
1

Answer by aldonaletto · Jan 18, 2013 at 01:50 AM

I used the CharacterController in a bike once, and set its height and radius so that it became a sphere instead of a capsule - but the original shape may work as well. The CharacterController itself doesn't rotate, but the transform can be rotated freely to align to the ground. Take a look at this question, which uses a CharacterController - my answer shows a way to align to the ground smoothly. @SirGive (the question poster) also posted another interesting method to do the same, maybe more suitable for a bike.

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 CuddleMonster · Jan 18, 2013 at 03:26 AM 0
Share

I've been trying to make this work... but my lack of experience in C# makes me useless in this situation. Would you know how to convert it to JS?

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

12 People are following this question.

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

Related Questions

Flip over an object (smooth transition) 3 Answers

How to rotate and move object use dual joysticks in Iphone 2 Answers

Lock Z Rotation. Character Controller. 1 Answer

How rotate the cam by acceleration 0 Answers

My vehicle sinks underground when it's rotated on the Z axis 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