Obi Official Forum
FishingRod and SmoothCursor? - Printable Version

+- Obi Official Forum (https://obi.virtualmethodstudio.com/forum)
+-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html)
+--- Forum: Obi Rope (https://obi.virtualmethodstudio.com/forum/forum-4.html)
+--- Thread: FishingRod and SmoothCursor? (/thread-1239.html)



FishingRod and SmoothCursor? - ayoci - 21-06-2019

hi. Sonrisa

Obi Rods suitable for FishingRods(bending, custom 3d model)? 

And

I'm calculating the rope stretch with:
Code:
stretch = rope.CalculateLength() - rope.RestLength;
 if 0 or negative the rope not stretched, but if i use 
Code:
cursor.ChangeLength(rope.RestLength + hookExtendRetractSpeed * 15 * Time.deltaTime);

I want to simulate the opened reel when stretch > 0

My Stretch value goes extremely high. my default stretch when i'm moving with the rod 0.1-0.2 but if i use Cursor this value goes between: 0.8-!!16!! and my rope breaks instant. I'm using it wrong?  Or ObiRope has smoothCursor? Sonrisa


RE: FishingRod and SmoothCursor? - josemendez - 27-06-2019

(21-06-2019, 03:49 PM)ayoci Wrote: hi. Sonrisa

Obi Rods suitable for FishingRods(bending, custom 3d model)? 

And

I'm calculating the rope stretch with:
Code:
stretch = rope.CalculateLength() - rope.RestLength;
 if 0 or negative the rope not stretched, but if i use 
Code:
cursor.ChangeLength(rope.RestLength + hookExtendRetractSpeed * 15 * Time.deltaTime);

I want to simulate the opened reel when stretch > 0

My Stretch value goes extremely high. my default stretch when i'm moving with the rod 0.1-0.2 but if i use Cursor this value goes between: 0.8-!!16!! and my rope breaks instant. I'm using it wrong?  Or ObiRope has smoothCursor? Sonrisa

Hi there,

If you're using high enough values for hookExtendRetractSpeed, expect a sudden change in rope RestLength, but not in actual rope length until constraints have had a chance to react to the new length. This would cause a huge spike in strain (the difference/ratio between rest length and actual length), which is what you're seeing.

There's no such thing as a smoothCursor. A particle based rope is a discretization of a real-world continuous body, as such when you change its length, new discrete chunks of rope (particles) must be added.

My advice would be to use a low-pass filter on your "stretch" value, so that you can ignore sudden spikes.