21-02-2019, 09:43 AM
(21-02-2019, 09:37 AM)ChumLee Wrote: Thanks for these suggestions. Really helpful! It's starting to resemble an actual fly fishing line.
Another question: is there are a way to attach an Obi Rope to the end of an Obi Rod? I see that you can attach Unity rigid bodies to Obi objects, but I haven't seen anything about attaching Obi objects together.
I've already used an Obi Rod to mimic the flex profile of a fly rod (see below). That's all good in a visual sense, but the missing ingredient is actually having the line follow the rod tip as it bends. Right now the line, a sibling game object of the rod, is just using fixed particles to position itself. So as the rod bends, it doesn't react. Ideally, I could fix the first few rope particles to the final particle at the top of the rod. Is there a way to do that? Is it possible with scripting?
You could do this in several ways.
Using stitch constraints to attach the last particle or the rod to the first particle of the rope is a possibility, however this would add an additional constraint between both particles that would not look very good when swinging at high speeds.
Another (better) possibility is to position the rope transform at the end of the rod every physics step, by copying the particle's position/orientation to the rope's transform. You can get particle properties such as positions and orientations quite easily:
http://obi.virtualmethodstudio.com/tutor...icles.html