Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  How to add particles to existing cloth object
#3
(09-10-2018, 08:57 AM)josemendez Wrote: Being a cloth simulator, Obi does not provide any way to deal with this.

You will have to code your own solution. The simplest thing that comes to mind is using barycentric coordinates to store each particle's position relative to its closest triangle, and update them as the mesh deforms. You can get the deformed cloth mesh each frame like this:

Code:
obiClothComponent.clothMesh

cheers,

Got it!

Also, is there a way to reliably drag the cloth using mouse input? The current unmodified ObiClothDragger script does quite "drag" around the selected vertex with the mouse.

Specifically, I want the selected vertex on GetMouseButtonDown(0) to move under the exact mouse pointer's position on GetMouseButton(0).

Thanks
Reply


Messages In This Thread
RE: How to add particles to existing cloth object - by arrnav96 - 09-10-2018, 02:25 PM