I’m just joined roblox studio and script stopped working .Local script:
local Camera = script.Parent.Parent.CurrentCamera
script.Parent.MouseButton1Click:Connect(function()
script.Parent.Camera:Play()
Camera.Value = game.Workspace.Cameras["1B"]
end)
while wait(0.01) do
if script.Parent.Parent.CurrentCamera.Value == game.Workspace.Cameras["1B"] then
game.Workspace.Cameras["1B"].Checking.Value = true
else
game.Workspace.Cameras["1B"].Checking.Value = false
end
end
If not, try verifying if the script (or whatever you’re doing inside of the script) actually runs. An easy way to do this is by putting print()statements in some parts of your code. Your next steps will depend on where the code stops or whether it runs at all.
local Camera = script.Parent.Parent.CurrentCamera
script.Parent.MouseButton1Click:Connect(function()
script.Parent.Camera:Play()
Camera.CameraSubject = game.Workspace.Cameras["1B"]
Camera.CFrame = game.Workspace.Cameras["1B"].CFrame
end)
while wait(0.01) do
if script.Parent.Parent.CurrentCamera.CFrame == game.Workspace.Cameras["1B"].CFrame then
game.Workspace.Cameras["1B"].Checking.Value = true
else
game.Workspace.Cameras["1B"].Checking.Value = false
end
end