Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  Can I attach particeattachment in script?
#26
(21-10-2024, 11:06 AM)josemendez Wrote:
Code:
cloth.oneSided = true;

This allows particles to only collide with the side their normal vector is pointing towards. So if another particle tries to collide with its backside, it will be projected to the front.

See the "OneSidedCollisions" sample scene.


In that case, you need to access the blueprint's constraint data. (blueprint.distanceConstraintsData, skinConstraintsData, and so on). These contain constraint batches, that are accessed an modified just like they are at runtime. The only difference is that these are stored in the blueprint, instead of the solver.


Yes, invMass is just 1/mass. You can convert between them anytime you need. Be careful with division by zero.

The reason Obi uses inverse mass internally is to avoid having to perform a division thousands of times every single frame during simulation, so using inverse mass is considerably more efficient.


Code:
group.particleIndices

Please check the API docs.


That's not possible using the transform component as I just explained. All existing cloth systems (including Unity's built-in cloth) have the same limitation, as it is simply a consequence of how matrix algebra works. Try scaling Unity's cloth at runtime and see.

The only way to do what you want is to modify is to calculate your own pivot point (could be the cloth's center of mass, a fixed point, whatever you agree on) and perform the transform yourself on particle positions directly, after simulation has been carried out.
Hello. Thank you for your explanation. Now I can get each groups' particles' actual indices easly. Now, I just created blueprint in obi 6 folliwing your trench coat blueprint of obi 7. My clothing asset keeps jittering  like a video I uploaded.

video youtube link

this clothing mesh asset has inside and out side  surface. I even changed all property values to particles in torso part, but arm particle and neck particles keep jittering. I also folllowed solver property in body in character cloth sample scene in obi 7
Reply


Messages In This Thread
RE: Can I attach particeattachment in script? - by gahyun11 - 22-10-2024, 11:15 AM