Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Resize rope when apply force to attached mass
#3
(08-07-2024, 12:02 PM)josemendez Wrote: Hi!

You can get any per-particle value (velocity, position, size, etc) using the particles API. To get the index of the first particle on the rope, you should use the rope's elements array.


By definition, the tension at rest or any object is zero. Maybe you're interested in strain instead, which is the % of deformation caused by tension? You can calculate it like this:

Code:
float strain = rope.CalculateLength() / rope.restLength;

It will be 1 when the rope is at rest, >1 if stretched, <1 if compressed.

kind regards
Thank you very much! This should help.
Reply


Messages In This Thread
RE: Resize rope when apply force to attached mass - by Jaxel - 08-07-2024, 01:15 PM