I have a problem where when my interactive cloth stops moving and rests, it then no longer updates for the rest of the session.
E.g. the cloth falls on a flat surface, has its physics collision and deforms, then finally goes still and rests. Then if the surface were to move, the cloth would just stay where it fell and does not move.
If this surface was moving in the first place and didn’t allow the cloth to stop moving then it will interact as I expect it to, but why does it go into a sort of hibernation mode that it can’t recover from when it stops?
Is there any way I can re-enable it? The gameobject and all components still show active when it stops.
I didn’t realise this thread got bumped, for anyone that is having this problem I had a workaround, although it isn’t ideal.
In a similar approach to phoenix0330, I just implemented a script that would add a downwards force of -0.01f at every fixed update, but also counter-balanced this with an external acceleration in the interactive cloth component.
Same problem. Interactive cloth comes to rest then stops updating. Doesn’t matter how many other colliders or physics objects intersect it after it stops updating -nothing can make it move
For any future readers: Solution is pretty simple in my case.
For me, the cloth would stop simulating after its parent GameObject was disabled and reenabled. I was able to get the cloth to move again by disabling the cloth component and reenabling it also.
Specifically…
parentGameObject.SetActive (false);
//Doing stuff
//I want it back again
parentGameObject.SetActive (true);
This is where the cloth would stop working. So my solution was to just add these two lines as shown.
parentGameObject.SetActive (false);
//Doing stuff
//I want it back again
parentGameObject.SetActive (true);
clothChild.GetComponent.<Cloth>().enabled = false;
clothChild.GetComponent.<Cloth>().enabled = true;