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

How to rotate a union with Tween Service?

I tried 2 ways to rotate it, but none worked. Here are my scripts: 1st method:


spawn(function()
	while true do
		local tween = tweenService:Create(child, TweenInfo.new(1), {Orientation = union.Orientation + Vector3.new(120, 0, 0)})
		tween:Play()
		tween.Completed:Wait()
	end
end)

2nd method:

spawn(function()
	while true do
		local tween = tweenService:Create(union, TweenInfo.new(1), {CFrame = union.CFrame*CFrame.Angles(120, 0, 0)
		tween:Play()
		tween.Completed:Wait()
		local tween2 = tweenService:Create(union, TweenInfo.new(1), {CFrame = union.CFrame*CFrame.Angles(240, 0, 0)
		tween2:Play()
		tween2.Completed:Wait()
		local tween3 = tweenService:Create(union, TweenInfo.new(1), {CFrame = union.CFrame*CFrame.Angles(360, 0, 0)
		tween3:Play()
		tween3.Completed:Wait()
	end
end)

1 answer

Try this:

spawn(function()
	while true do
		local tween = tweenService:Create(union, TweenInfo.new(1), {Orientation =union.Orientation + Vector3.new(360, 0, 0)
	end
end)

1 comment

0

:)

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