Frictional Games Forum (read-only)

Full Version: AttachPropToBone alternatives
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
In Machine for Pigs, there is a script called AttachPropToBone, which attaches the centrifuge arms to the shuttles placed in it. I'm assuming it's used to connect a prop with an animated model. Here's an example:

AttachPropToBone("Shuttle_3_1", "CentrifugeArms", "compound_C_bone", 0.0f , 0.0f, 0.0f, 22.625f, 2.014f, -25.091f);

Unfortunately, this script doesn't exist in either TDD or the patch that is being released. Is there any other way to attach the shuttle to the arms of the centrifuge? I tried using AttachPropToProp, but the shuttle didn't appear when I used it. I tried just leaving the shuttle in there unattached, but it appears the centrifuge's actual Bodies stay put during the animation, so the shuttle just hovered there while it spun.

EDIT: Figured it out myself! I just scratched the animation altogether and rotated the model with a script. By placing the shuttles as static physics and making them rotate at the same speed, it essentially duplicated what I had in mind.