Basically, I'm attempting to make a main menu with a cutscene, for my game, and I made this script:
local event = game.ReplicatedStorage.BoardClicked script.Parent.MouseClick:Connect(function(click) event:FireClient(click) end)
which activates the remote event, and then I have this local script in StarterGui:
local tweenservice = game:GetService("TweenService") local camera = game.Workspace.Camera local loading = script.Parent:WaitForChild("Loading") local cutscenetime = 2 local tweeninginfo = TweenInfo.new( cutscenetime, Enum.EasingStyle.Sine, Enum.EasingDirection.Out, 0, false, 0 ) function tween(part1,part2) camera.CameraType = Enum.CameraType.Scriptable camera.CFrame = part1.CFrame local tween = tweenservice:Create(camera,tweeninginfo,{CFrame = part2.CFrame}) tween:Play() end tween(game.Workspace.CutsceneParts.CutscenePart2,game.Workspace.CutsceneParts.CutscenePart3) game.ReplicatedStorage.BoardClicked.OnClientEvent:Connect(function() tween(game.Workspace.MenuRoom.CutsceneParts.CutscenePart2,game.Workspace.MenuRoom.CutsceneParts.CutscenePart3) game.Workspace.MenuRoom.MenuBoard.MenuPart.Clicker:Destroy() end)
What's wrong with it?
Crap. I figured it out. I moved the cutsceneparts and forgot to edit one of the code lines.