Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 LeoSaurusRex · May 25, 2016 at 02:17 AM · physicsrigidbodykinematic

Problem With Kinematic Children

hello, so i have my player who can walk up t crates and on the press of a button the crate becomes its child (to simulate backwards dragging). on the release of the button the crate loses its parent attachment. now i am doing this by setting the child's rigid body as kinematic and disabling kinematic. the only problem with this is that since its kinematic it goes through walls and stuff. it's not a fun-killer but it looks ugly and breaks the feel of the game. how can i go around this? can i drag crates any other way than parenting it and setting it as kinematic? now keep in mind that its a 3d game, the crate needs a rigid body because of the way it has to behave when not being dragged etc. oh and yes, everything has colliders, (mostly box colliders).

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

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by JedBeryll · May 25, 2016 at 04:46 AM

You can try joints. Fixed joint for example. That way you can keep it non-kinematic and no need for parenting. Give a joint to the player (or its hand or however you want it) and assign the crate's rigidbody to the joint's connectedBody.

http://docs.unity3d.com/Manual/class-FixedJoint.html

Comment
Add comment · Show 3 · 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 LeoSaurusRex · May 25, 2016 at 03:47 PM 0
Share

okay, that makes sense! now i'm gunna show a little noobness but whatever. i added a fixed joint to my player character (who also happens to be a rigid body) and he didn't move unless he had a connected body set, now that;s not ideal since the player has to walk up to the crate and press a button. am i missing something? or is this method not ideal since my player character is also a rigid body???

avatar image JedBeryll LeoSaurusRex · May 25, 2016 at 07:09 PM 0
Share

One way would be to set the fixed joint's connectedAnchor on its own position in Update or FixedUpdate. (yeah sounds pretty unprofessional). Other is to add the fixed joint to the crate (it works as long as you don't want it to move any other way).

avatar image LeoSaurusRex JedBeryll · May 30, 2016 at 04:54 PM 1
Share

thank you Jed, really appreciate your help! i was forced to change the way i handle crate movement so this no longer presents an issue, either way thank you!

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

4 People are following this question.

avatar image avatar image avatar image avatar image

Related Questions

Guidelines for using rigidbody, collider, CharacterControllerScript, etc? 3 Answers

Using kinematic rigidbody on parent for disable enable mesh collider and primitive collider children? 1 Answer

How can i Prevent Kinematic object not to pass through another rigidbody object 1 Answer

Simple Movement Game: Physics vs Manual Collision Detection? 2 Answers

Disable ragdoll without changing Kinematic boolean? 2 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