How would I go about tweening the camera around a point?

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve? Keep it simple and clear!
    Tween the camera like so:

  2. What is the issue? Include screenshots / videos if possible!
    I don’t think tweenservice works the same on cameras

  3. What solutions have you tried so far? Did you look for solutions on the Creator Hub?
    yes, couldn’t find anything
    After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!

script.Parent.MouseButton1Down:Connect(function()
	workspace.CurrentCamera.CameraSubject = workspace.Point1
end)
--this didn't work


local camera = workspace.CurrentCamera
local part = workspace.View1 --Your Part
script.Parent.MouseButton1Down:Connect(function()
	camera.CameraType = Enum.CameraType.Custom
	wait(.1)
	camera.CameraType = Enum.CameraType.Scriptable
	camera.CFrame = part.CFrame
end)

didn’t work

--didn't either
local TweenService = game:GetService("TweenService")
local RunService = game:GetService("RunService")
local camera = workspace.CurrentCamera

script.Parent.MouseButton1Down:Connect(function()
-- Create a proxy part to tween
local camPart = Instance.new("Part")
camPart.Anchored = true
camPart.CanCollide = false
camPart.Transparency = 1
camPart.Position = camera.CFrame.Position
camPart.Parent = workspace

-- Tween that part to a new position
local goal = {Position = Vector3.new(50, 10, 0)}
local info = TweenInfo.new(2, Enum.EasingStyle.Sine, Enum.EasingDirection.Out)
local tween = TweenService:Create(camPart, info, goal)

-- Camera follows the part
RunService:BindToRenderStep("CameraTween", Enum.RenderPriority.Camera.Value, function()
	camera.CFrame = CFrame.new(camPart.Position, Vector3.new(0, 0, 0)) -- Look at (0, 0, 0)
end)

tween:Play()

-- Stop following when tween finishes
tween.Completed:Connect(function()
	RunService:UnbindFromRenderStep("CameraTween")
	camPart:Destroy()
end)
end)

that last one was from chatGPT tbf tho

Please do not ask people to write entire scripts or design entire systems for you. If you can’t answer the three questions above, you should probably pick a different category.

Nevermind, for anyone who wants to do this, you have to the script in StarterCharacter and run it from there, using

game.Players.LocalPlayer.PlayerGUI.TextButtonYouWant.MouseButton1Down:Connect(function()

end)

NEVERMIND AGAIN, I still can’t tween it, only fix the camera to a point (in which it just snaps)

NEVERMIND AGAIN AGAIN, I can I’m just a donkey, and did the script wrong

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.