I need help on getting a local script that enables a certain camera manipulation and then disables after a certain time. Can someone help me with it since it doesn't work. I tried to clone the camera local script from ReplicatedStorage to StarterGui then destroys the script so that the camera stops, but it didn't work why?
game.ReplicatedStorage.Camera:Clone().Parent = game.StarterGui wait(15) game.StarterGui.Camera:Destroy()
Why parent a camera to starter gui? CurrentCamera is the best way, because you'd be configuring the options for the player's camera.
local Camera = workspace.CurrentCamera -- If you want just the localplayer's camera to change, configure the camera using a localscript. Camera.CameraType = "Custom" -- You'll need more understanding to use the camera types.
You could use CameraSubject
to change the cameras primary focus part.
It's some cool stuff.
Heres how I did it
local camera=game.Workspace.Camera local cameraposition=script.Parent.PartPos --This is for the position of the camera repeat Camera.CameraType=Enum.CameraType.Scriptable untilCamera.CameraType==Enum.CameraType.Scriptable -- I know this looks extreme but it ensures that the cameratype changes properly repeat Camera.CFrame=cameraposition.CFrame until Camera.CFrame==cameraposition.CFrame
Tell me if you find a better solution