07-10-2019, 01:32 PM
(This post was last modified: 07-10-2019, 01:33 PM by josemendez.)
(07-10-2019, 12:33 PM)Sany02 Wrote: I have a tap that fills the container on tapping screen by changing emitting speed. After the container fills, it moves to a position. But during that movement the water inside the glass(container) fall through the glass. If anybody could help me that would be great. Plus I also want to increase the amount of water that should flow through the tap. I tried increasing the radius of particle renderer but it doesn't look so great. So any tips on that would also be very helpful. Thanks.
Hi,
This issue commonly referred to as tunneling, exists in all physics engines and is inherent to how time is represented in computers as a discrete quantity, instead of a continuous one. Basically every time you move an object by changing its transform's position, you're actually "teleporting" it around. It its walls are thin enough compared to the size of your particles and to the amount of space it has teleported in a frame, you will leave particles outside of it because the container walls simply disappeared and reappeared in a completely different position the next frame.
Obi performs continuous collision detection (CCD) to alleviate this, but will only work if it can work out a speed for your container. Either add a ObiKinematicVelocities to it, or use forces to move it around instead of directly setting its position.
To increase the amount of water flowing from an emitter, increase its "speed" parameter. It controls both the amount of liquid as well as its velocity, just like a real-world faucet.