Jump to content

How to tackle the movement of a rope prim between two other prims


Miguelito Shilova
 Share

You are about to reply to a thread that has been inactive for 3260 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

I would consider purchasing a script that did this, but I didn't see one in Marketplace (or wasn't looking in the right place) ...

I am working on a new boat build, and one of the things I'd like to include is a functional mainsheet - the rope that connects the sail boom to the hull. As to be expected, the boom connects to the mast and swings around it in a wide arc. The mainsheet is about 3/4's of the way aft of the mast, on the boom. The intent is that when the boom swings, the endpoints of the mainsheet 'rope' prim will stay on the same spot of the boom and the hull of the boat - extending and rotating the mainsheet on all three axes.

I have seen this done many times on boats, so it's just a matter of understanding how. Can someone offer up some advice on how to tackle this task?

Much appreciated!

Mig

Link to comment
Share on other sites

As Dora suggests a particle script is the thing to use, at least I don't know of any other way to have a rope that stretches.and moves. It may not look pretty but it is what we have.

Here is a better example although you will still need to do some work on it I expect to get it to meet the requirements of your build.

Make a small emitter prim to put this script in and attach it to the hull. Then another prim to be the target attached to the boom. You need to get the UUID of the target prim. An easy way to do that is to create a new script in the prim and change the default script line llSay(0, "touched"); to llSay(0, llGetKey());. Then when you click it it will say its UUID and you can copy it from chat.

default{    // you will need to change the PSYS_SRC_TARGET_KEY for the UUID of your target prim.        state_entry()    {                list rope_effect = [PSYS_PART_FLAGS,                                                         PSYS_PART_FOLLOW_VELOCITY_MASK |                 PSYS_PART_TARGET_POS_MASK |                 PSYS_PART_FOLLOW_SRC_MASK |                 PSYS_PART_RIBBON_MASK,                                PSYS_SRC_PATTERN,           PSYS_SRC_PATTERN_DROP,                PSYS_SRC_TARGET_KEY,        (key)"d4ca4c7d-4970-1355-2eae-6defa232c1df",                PSYS_PART_START_ALPHA,      1.0,                PSYS_PART_END_ALPHA,        1.0,                PSYS_PART_START_SCALE,      <0.2,0.2,1.0>,                PSYS_PART_END_SCALE,        <0.2,0.2,1.0>,                PSYS_SRC_TEXTURE,           "bc586d76-c5b9-de10-5b66-e8840f175e0d",                PSYS_SRC_BURST_PART_COUNT, 10,                PSYS_PART_MAX_AGE,          2.5,                PSYS_SRC_BURST_RATE,        0.005,                PSYS_SRC_BURST_PART_COUNT,  1            ];                        llParticleSystem(rope_effect);    }    }
Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 3260 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...