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 mEan · Feb 18, 2014 at 06:20 PM · physicsfpsfast

Problem with fast physics

Hello,

i am trying to simulate rotating hammer (no gravity, kinematic) colliding a ball, something like croquet. Everything works well until i rotate the hammer really fast. Sometimes the ball sticks to the hammer, sometimes the ball ignores the collision.

I think when the rotation is too fast, the hammer goes through the ball or appears in the middle between frames. So i am not able to hit the ball fast. Is there any solution for this? Putting the rotation into FixedUpdate didn't work.

Thanks

Comment
Add comment · Show 3
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 whydoidoit · Feb 18, 2014 at 06:21 PM 0
Share

You;ve got interpolation and/or extrapolation turned on? Could also try changing the rotation of the rigidbody with $$anonymous$$oveRotation and you are rotating the rigidbody not the transform right?

avatar image POLYGAMe · Feb 18, 2014 at 07:07 PM 0
Share

If ypu're doing all of the above and still have issues, you can also adjust the fixed time step for more accurate physics. Other than that, you'll have to do some mathy stuff... taking the hammer''s velocity, estimating where it will be on the next frame and deter$$anonymous$$ing if there should be a collision from that. I haven't had to do anything like that yet but there is a script here:

http://wiki.unity3d.com/index.php?title=DontGoThroughThings

avatar image mEan · Feb 21, 2014 at 11:37 AM 0
Share

Thank you both for your answers. Rotating the rigidbody ins$$anonymous$$d of transform helped alot, now it behaves more realistic. I also tried to set interpolate and dynamic collision detection and it seems to be the best settings.

But the problem still occurs when the movement is really fast, event with $$anonymous$$imum fixed time. I think the only solution left is to do some coding, but i cannot use the script you posted above since the movement is rotational, the object position doesnt change. So i think i cannot use raycasting here. Do you have any idea how to modify this script for my case?

Thank you

0 Replies

· Add your reply
  • Sort: 

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

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

Related Questions

How to stop an rigidbody enemy from jumping when chasing the player? 1 Answer

i need help with my skateboard physics 0 Answers

RigidBody.MovePosition seems jerky in movement 0 Answers

Is there support for continuous collision detection / fast collision detection in unity? 2 Answers

Why can't I shoot my bullet down? 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