10-09-2018, 04:27 PM
(This post was last modified: 10-09-2018, 04:45 PM by josemendez.)
(10-09-2018, 04:03 PM)arrnav96 Wrote: Just tried doing what you mentioned. Made no difference. Sphere sinks straight through it. Even went up to 4 substeps and 8 distance contraint iterations. Same result. May I send you the project so you can have a look? Nothing I try seems to make a difference here.
Here:
The video starts with the basic cloth setup: Create a GameObject with cloth & solver components, choose a cloth topology (I have multiple ready-made ones, so I skipped topology generation) and hit "Initialize".
Then I fix the four corners of the cloth (similar to the setup you describe), and create a 1 kg ball on top of it.
Click play, and the ball sinks trough the cloth. ([1:18] in the video)
Note that I left the cloth mass at its default value of 0.1 kg per particle, for the sake of demonstrating iterations/substeps only. First I try 5 iterations / 2 substeps. Since the cloth mesh is quite dense -made out of many particles- and light, the ball still slips trough. Then I try 5 iterations / 4 substeps, and now cloth is able to withstand the weight of the ball, despite having a mass ratio of 1/10. Reducing the mass ratio by increasing the weight of the cloth would reduce the need for high iteration/substep counts, reducing the density of the mesh would too.
After that, I add a particle renderer component so that you can see the cloth particles. Then begin to reduce the amount of substeps again, until the ball is able to rip a gap between the particles and slip trough.
Hope the video helps you.
PS: I have a feeling that your original goal got lost during this conversation... assuming your slime sim is 2D, I think it would be both easier and much more performant to simply move particles around directly (those near the user's finger), using Oni.SetParticleVelocities()?