Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  Make the rope float
#2
(24-10-2022, 12:14 AM)Slava Wrote: I have an idea how this can be done.To do this, I must get the location of particles in world space. And then check if they are in the water, then move them in the right direction or use force on them. Is it possible to do that? If yes, then how?

Hi,

Yes, that's the right approach. You can get/set any per-particle property using the particles API:
http://obi.virtualmethodstudio.com/manua...icles.html

If you want  to apply forces to particles, write into the solver's externalForces array. If you want to apply accelerations, use the solver's velocities array instead. Note all properties are expressed in the solver's local space, you will need to convert to/from world space using the methods defined in Unity's transform class.

kind regards,
Reply


Messages In This Thread
Make the rope float - by Slava - 24-10-2022, 12:14 AM
RE: Make the rope float - by josemendez - 24-10-2022, 07:39 AM