script.Parent.Parent.PlayerGui:WaitForChild("ScreenGui").Frame.TextButton.MouseButton1Click:Connect(function()
print(1)
if not workspace.CurrentCamera.CameraType == Enum.CameraType.Scriptable then
print(2)
workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable
workspace.CurrentCamera.CFrame = workspace.CameraParts.Cameracframe.CFrame
workspace.CurrentCamera.Focus = game.Workspace.CameraParts.Camerafocus.CFrame
else
print(3)
workspace.CurrentCamera.CameraType = Enum.CameraType.Custom
end
print(4)
end)
When I run the script and press the button, it does not work, it only ever prints out 1,3 and 4 even if my cameratype is not scriptable