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
0
Question by SYRSA · Jul 10, 2013 at 11:12 PM · vehiclelocomotion system

Leg locomotion issue on crawler vehicles

I have gone desperate for solutions on how to setup a proper locomotion system on vehicles that has crawler legs: This one --> https://www.dropbox.com/s/lqa5qrrzy97dwuw/Walker.png

I am using Runevision's Locomotion System. But I fail to get it right because the legs just flails about, dislodges and fails to stay level with the vehicle it's attached to.

The way I have setup this vehicle is that it rolls on invisible wheel colliders that makes it move. And I have attached the legs on a child GameObject inside the vehicle with a locomotion system to simulate the walking. But it just won't behave itself. Any help?

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 Kiloblargh · Jul 11, 2013 at 02:28 AM 0
Share

This is a modeling and not a scripting issue but I have to comment on the design of those legs- the knees look weak and unworkable. They should be way bulkier; and maybe have some visible hydraulics underneath. Look at the tank from Ghost In the Shell, for inspiration- I know that's a futuristic anime style and yours is more dieselpunk, but the physics of the masses involved are the same. (Apart from the legs though, I love the design!)

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Kiloblargh · Jul 10, 2013 at 11:26 PM

I would just animate parent objects of the legs in a fixed walk cycle, and then rotate each of the actual leg joints relative to their parents by some pre-calculated fudge factors times the height of that foot off the terrain.

Comment
Add comment · Show 4 · 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 SYRSA · Jul 11, 2013 at 12:51 AM 0
Share

Well, the issue here is that I cannot animate the parent object because it is built around a complex vehicle script that includes other moving objects that relies on physics.

I want a solution so I can have the legs to move in tandem with the vehicle that it is connected to.

avatar image SYRSA · Jul 11, 2013 at 01:20 AM 0
Share

Well, I could do the option which is to drop the locomotion topic for the sake of more assistance.

And use a simple animation system that will switch between states of walk cycles based on the movement of the vehicle. So, can anyone help me with that?

I have made 4 animations of the legs which is forward, reverse, turning left and right. But how would I make them animate and blend with the direction the vehicle is going?

avatar image Kiloblargh · Jul 11, 2013 at 02:13 AM 0
Share

The legacy animation system tutorial has an example of animation blending; in general it's kind of a pain in the ass to get working right at first but it's definitely doable. Lerp and InverseLerp and trial and error.

I would ditch the Locomotion System- it's made for legs where the hip is above the knee is above the foot, your legs have the knee above the hip, which confuses it. What I'm saying is- forget I said parenting, don't do that- you make invisible legs that you'd animate just like normal legs walking on a level surface, and then you have a script that each frame first positions the visible legs exactly the way the invisible animated ones are positioned, then measures from each invisible foot to the ground and adjusts the rotation of the joints on the visible legs to raise or lower them accordingly.

avatar image SYRSA · Jul 11, 2013 at 02:55 AM 0
Share

Ok. So how would I go about and make sure so it will work how I have set it up? The legs are supposed to be attached as a child in the vehicle. So how do I set it up so the legs will play the animations and blend them due to angular and directional motion?

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

15 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 avatar image avatar image avatar image

Related Questions

Vehicle (tank) for my character 1 Answer

Weapons on vehicle 1 Answer

Raycast align with ground normal 2 Answers

How to turn of collision for the player 1 Answer

Boat movement, driving and animation 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