Im trying to make a script in which when players touch an object there camera is the position of a part i put this is a local script:
local Camera = script.Parent.CameraWhenHiding.CFrame
local humanoid = game.Players.LocalPlayer:WaitForChild("HumanoidRootPart").CFrame
local TrashCan = script.Parent
TrashCan.Touched:Connect(function(hit)
humanoid = Camera
end)

12 comments
It didnt work when i touched the trashcan my view didnt change to the part
I edited it,
Still doesnt work my camera doesnt turn to what the CurrentCamera sees
What are you trying to do?
When i touch the trash can i want my camera to seewhat the CameraWhenHiding sees
I edited it again
It still didnt work nothing happened
edited it AGAINN
Still didnt work xd
Anything in the output?
NOTHING IN THE OUTPUT
ILL ACCEPT IF IT WORKS :)