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

How do I make the Camera move smoothly to look at a part?

I am trying to make the player's camera move when they hit a gui. But the only problem is that this error keeps on coming up. But I can't figure out how to fix it. The script is

local Workspace = game:GetService("Wrokspace") local TeenService = game:GetService("TweenService")

local CurrentCamera = Workspace.CurrentCamera

function OnClick() CurrentCamera.CameraType = Enum.CameraType.Scriptable local TI = TweenInfo.new(5, Enum.EasingStyle.Quad, Enum.EasingDirection.In, 1) local Goal = (CFrame = Workspace.BigShip.CFrame) local Animation = TeenService:Create(CurrentCamera, TI, Goal) Animation:Play()

The Error : 17:34:37.267 - Players.NovaGooBoom.PlayerGui.ScreenGui.TextButton.Upgrade Thing:9: Expected ')' (to close '(' at column 14), got '='

1 answer

✓ Accepted answer

game:GetService("Workspace") is spelt wrong

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