Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Textbutton can't be clicked?

Asked by 7 years ago
Edited 7 years ago

This script won't connect

script.Parent.MouseButton1Down:Connect(function()
    game.Workspace.CurrentCamera.CameraSubject =            
        game.Players.LocalPlayer.Character.Humanoid
        game.Workspace.CurrentCamera.CameraType = Enum.CameraType.Custom
end)

2 answers

Log in to vote
1
Answered by 7 years ago

You miss typed

Should look like this:

script.Parent.MouseButton1Down:connect(function()
    game.Workspace.CurrentCamera.CameraSubject = 
game.Players.LocalPlayer.Character.Humanoid
    game.Workspace.CurrentCamera.CameraType = Enum.CameraType.Custom
end)
Ad
Log in to vote
0
Answered by
GingeyLol 338 Moderation Voter
7 years ago

Use a localscript

and why don't you just do

game.Workspace.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Humanoid

instead of indenting

Answer this question