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 kikillo · Mar 28, 2013 at 07:01 PM · physicsballclothinteractive clothinteractivecloth

Objects go through InteractiveCloth, why?

I'm simulating a basketball game, and I have the net with the basket, attached and it mostly works ok.

But recently I've had to adjust the distance and the balls are getting through the ring faster than before. And now most of the times the ball just goes through one of the "cracks" inside the net The net is a cilinder, with a shorter end on one side things that I have tried: - increased thickness (cant increase more or the ball won't go through) - increased friction (same thing) - decrease "stretching stiffness" (the whole net stretches to infinity due to gravity

Anyways, I've tried changing all the parameters in the interactive clothing but I can't accomplish the results that I want. If the ball goes slowly enough this doesn't happen though. Basically I'm wondering why this happens, and how to solve it, looking for something other than the settings in the interactive cloth component. Maybe I'm missing something. I will try every suggestion you give me.

TL;DR the ball goes through the net if it's thrown just a bit fast. What could be happening here? is it a bug?

Comment
Add comment · Show 5
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 Loius · Mar 28, 2013 at 07:26 PM 0
Share

Cloth physics are hards.

$$anonymous$$y suggestion would be to change the ball's rigidbody physics to 'Continuous' ins$$anonymous$$d of 'Discrete'. The hope would be that the ball would then push its way from point to point ins$$anonymous$$d of sorta-teleporting.

avatar image kikillo · Mar 28, 2013 at 09:10 PM 0
Share

Thank you, I had already tried that too. In fact when I went to change it was already in continuous.

avatar image MojopinStudios · Apr 13, 2013 at 07:50 PM 0
Share

I am having a similar problem, regarding a soccer type net. The ball goes through the cloth if it comes at any angle other than straight on. Did you ever get a solution for this?

avatar image kikillo · Apr 13, 2013 at 10:19 PM 0
Share

The best I could do was increase as much as possible the thickness of the net, and the friction and basically all the values that would stop the ball a little bit. Since my net for the basket is a cylinder I can't increase the thickness too much or the ball won't go through. But maybe in your net you can increase thickness further. In the end all I could do to solve it was to move the characters closer to the basket, so the ball doesn't go too fast and it only happens rarely (but it still happens, mostly in the phone version) If the ball comes with enough strength and in certain angles it breaks it.

Here is my game on webplayer: bitly.com/memebasket and for Android: https://play.google.com/store/apps/details?id=com.$$anonymous$$llosoft.memebasket

avatar image kikillo · Sep 15, 2013 at 03:28 AM 0
Share

Co$$anonymous$$g back to this question, after a while, I believe that the reason could be simply the low floating point precision of current smart phones. Since this never happens in the 64 bit windows version. $$anonymous$$aybe it won't happen in the new samsung and iphone hardware.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Ryuuguu · Apr 03, 2014 at 01:55 PM

Cloths don't have real colliders they force interaction. if you can make a collider on another object follow the cloth.

I do not know if this nonCPU intensive or not but it works. Make a separate game object with a mesh collider as child at (0,0,0) position relative to the cloth. put in in a lyer that does collide with the cloth. This gives a mesh collider that follows the cloth.

put this on the object

 public InteractiveCloth cloth;
 public Mesh mesh;


 void Start () {
     mesh = (Mesh)Instantiate(cloth.mesh);
     GetComponent<MeshCollider>().sharedMesh = mesh;
 }

 void Update () {

     calcFreqCount = calcFreq;
     GetComponent<MeshCollider>().sharedMesh = null;
     mesh.vertices = cloth.vertices;
     GetComponent<MeshCollider>().sharedMesh = mesh;

}

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 miker88 · Jun 09, 2014 at 03:02 AM 0
Share

this will clash with the original cloth mesh and makes the whole cloth jumpy.

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

14 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

Related Questions

InteractiveCloth & ClothRenderer pauseWhenNotVisible issue 0 Answers

Unable to move InteractiveCloth with AddForceAtPosition 0 Answers

Strange problem with cloth 2 Answers

Unity 5.0.x Cloth physics issue. 1 Answer

Get a free moving ball. 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