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

PlayerAdded not working?

Asked by 9 years ago

I'm pretty sure that I did everything correctly, but why won't it work? Is it something to do with roblox or my piece of code? If someone could it would mean a lot. Nothing does what I want it to and I get nothing in the output.

Errors: none

Code:

game.Players.PlayerAdded:connect(function(plr)
    plr.CameraMode = Enum.CameraMode.LockFirstPerson
    plr.CharacterAdded:connect(function(char)
        local Humanoid = char:FindFirstChild("Humanoid")
        Humanoid.Jumping:connect(function()
            Humanoid.Jump = false
        end)
        --
    end)
end)

0
It's an event on the humanoid. YasuYoshida 171 — 9y
0
Try using the 'Changed' event instead. TheeDeathCaster 2368 — 9y
0
That fixed the jumping, but the CameraMode still won't work. YasuYoshida 171 — 9y
0
You have to get the camera from the player. FearMeIAmLag 1161 — 9y

Answer this question