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

Why wont my tweenservice rotate the doors?

Asked by 5 years ago
local tweenService = game:GetService("TweenService")

local door1 = script.Parent.Door1

local door2 = script.Parent.Door2



local tweeningInformation = TweenInfo.new(

1,

Enum.EasingStyle.Linear,

Enum.EasingDirection.Out,

0,

false,

0

)



local door1Close = {

CFrame = CFrame.Angles(0, math.pi/2, 0),

CFrame = CFrame.new(-711.728, 7.94, -64.345)

}



local door1open = {

CFrame = CFrame.Angles(0, math.pi/2, 0),

CFrame = CFrame.new(-711.728, 21.684, -64.345)

}



local door2close = {

CFrame = CFrame.Angles(0, math.pi/2, 0),

CFrame = CFrame.new(-711.727, 7.94, -51.645)

}



local door2open = {

CFrame = CFrame.Angles(0, math.pi/2, 0),

CFrame = CFrame.new(-711.727, 21.684, -51.645)

}



local tween1open = tweenService:Create(door1,tweeningInformation,door1open)

local tween1close = tweenService:Create(door1,tweeningInformation,door1Close)

local tween2open = tweenService:Create(door2,tweeningInformation,door2open)

local tween2close = tweenService:Create(door2,tweeningInformation,door2close)



script.Parent.Detector1.Touched:Connect(function(hit)

tween1open:Play()

tween2open:Play()

wait(2)

tween1close:Play()

tween2close:Play()

end)



script.Parent.Detector2.Touched:Connect(function(hit)

tween1open:Play()

tween2open:Play()

wait(2)

tween1close:Play()

tween2close:Play()

end)

they get the rotation 0, 0, 0

0
Any errors? SunxLightz 30 — 5y
0
nope, ik an experienced scripter so i would have given the errors, and if there would be errors i could probably solve it Gameplayer365247v2 1055 — 5y

Answer this question