Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

What is the problem with this Tween, CFrames and Welding combo?

Asked by 3 years ago
Edited 3 years ago

Hello guys! So I welded 3 part into one (as a test), and wanted to see how will it move with CFrames. I have Part1, Part2, Part3. Im using Tweening. I dont understand, what is the problem. In Part2 and Part3 are 1-1 WeldConstraint, it is welded how it should be. The position is good too, so i dont know... Part2 and Part3 are welded to Part1, if I try this with Vector3, the Part1 moves good, but as I know, you need to use CFrame to move welded objects, and if I set to CFrame and press the button nothing at all happens. This is the code:


local TweenService = game:GetService("TweenService") local Position = {} Position.CFrame = CFrame.new(44.3, 0.5, 80.9) local Part = script.Parent script.Parent.ClickDetector.MouseClick:Connect(function() local LinearOut = TweenInfo.new(2, Enum.EasingStyle.Linear, Enum.EasingDirection.Out, 0, false, 0) local Tweening = TweenService:Create(Part, LinearOut, Position) Tweening:Play() end)

Anyone know what is the problem? And one thing I didn't said, the 3 parts are in a group, and yes, the primarypart is Part1

0
Edit: The parts were not anchored, now they are anchored and move, but only the Part1, the 2 other parts that are WELDED are not moving. BlackFateX 19 — 3y
0
I fixed it, the problem was that only the main part needs to be anchored, none of the others. BlackFateX 19 — 3y

Answer this question