Why my part doesnt want to be tween

The sign probably isn’t anchored.

2 Likes

Thats working but, not like I want

I want the sign like have an effect of the wind like the first video

1 Like

The primarypart is the handler

No, the sign is not anchored but it still doesnt want to move…

1 Like

Is the Handler part anchored or unanchored?

no, the sign part is not anchored

Could you sent a RBXM of the sign so we can debug better?

singModel.rbxm (9.0 KB)

1 Like

u cant move models just by tweening their primary part

local TweenService = game:GetService("TweenService")
local part = game.Workspace:WaitForChild("Chapter2"):WaitForChild("Chapter")

local Tweeninfo = TweenInfo.new(
	3, 
	Enum.EasingStyle.Sine, 
	Enum.EasingDirection.InOut, 
	-1, 
	true
)

local cframeValue = Instance.new("CFrameValue")
cframeValue.Value = part:GetPivot()
cframeValue.Changed:Connect(function(newCframe)
    part:PivotTo(newCframe)
end)
local tween = TweenService:Create(cframeValue, Tweeninfo, {Value = part:GetPivot() * CFrame.Angles(math.rad(-50), 0, 0)})
tween:Play()
tween.Completed:Connect(function()
    cframeValue:Destroy()
end)

also use body constraints or render stepped if u want repeated rotation

I’ve figured it out. Your script is manipulating the Orientation which apparently welds don’t correlate with. I changed the script to manipulate the CFrame and it works.

local tween = TweenService:Create(part.PrimaryPart, Tweeninfo, {CFrame = part.PrimaryPart.CFrame * CFrame.Angles(math.rad(-50), 0, 0)})

Yes, thats working, thank you :slight_smile:

You can tween models if everything in the model is unanchored and welded to the anchored PrimaryPart.

which like 90% dont do :person_shrugging:

But thats what I did in the model but the sign didnt want to move

Just wondering, why are you creating a CFrameValue instead of just setting the cframe as a variable?

tracking variable changes is a hassle

You don’t need to track any changes at all, just this works without all the unnecessary stuff.

local tween = TweenService:Create(part.PrimaryPart, Tweeninfo, {CFrame = part.PrimaryPart.CFrame * CFrame.Angles(math.rad(-50), 0, 0)})

doesnt work if it aint welded which i already addressed so dont see ur point?

fyi this how i would do this

local rotationSpeed = math.rad(50)
RunService.RenderStepped:Connect(function(dt)
    part:PivotTo(part:GetPivot() * CFrame.Angles(rotationSpeed * dt, 0, 0)
end)

nice and simple

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.