Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do I keep added parts in an animation to rotate accordingly when played by a script?

I'm not sure how I can achieve this - I've scripted in a Motor6D like how it was on the player dummy:

local motor = Instance.new("Motor6D");
motor.Part0 = handle; --> handle is the "Right Arm" in this case
motor.Part1 = item.PrimaryPart;
motor.Parent = handle;

Still, I cannot get my sword to rotate like I customly did it in the animation. I don't know what I'm doing wrong for this not to work as I've put in the Motor6D where it was.

I've added a weld constraint too so the sword moves with the hand - but I don't think that has much effect as weld constraints freely allow you to rotate without having to set variables strictly.

1 comment

0

Check if your added parts are welded together as well as welded with the animated part. Also check if the animated part is actually moving and attached to the Dummy. If it isn't moving, it is likely that it doesn't recognize the Motor6D as with the animation.

1 answer

make sure the C0 and C1 is the same as the one on the dummy that you used to animate

3 comments

0

-1 as this is not a complete answer.

0

tf?? The least you can tell me is wether it works or not, what tf is an "complete answer"? You expect me to write the script for you or something? If the orientation and position are not the same then C0 and C1 most likely at fault, what more do you want

0

It didn't work - thanks for helping though.

This discussion is preserved as it was. New answers, comments, and votes are closed.