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

How to disable jumping?

Asked by
FiredDusk 1466 Moderation Voter
9 years ago

Here is the script:

local Player = game:service'Players'.LocalPlayer
local Character = Player.Character
local Humanoid = Character:findFirstChild("Humanoid")
Humanoid.Changed:connect(function()
    Humanoid.Jump = false
end)

I have put this in a local script and a normal script in workspace. Nothing happens!!

This is not a request.

1 answer

Log in to vote
0
Answered by
iSvenDerp 233 Moderation Voter
9 years ago

Hi. I Actully Made A Anti-Jump script last night! Im on Mobile so Sorry if the script looks weird.

game.Players.PlayerAdded:connect(function(player) -- This is when player joins

    player.CharacterAdded:connect(function(character)

        local humanoid = character:findFirstChild("Humanoid")-- We are making a variable for the Humanoid

        if humanoid then -- If player then

            humanoid.Changed:connect(function(property)--We are messing with the player now

                if humanoid.Jump == true then-- When the player trys to jump

                    humanoid.Jump = false -- This wont let Him.

                    humanoid.Sit = false

                    humanoid.PlatformStand = false

                end

            end)

        end

    end)



    local character = player.Character



    if character then

        local humanoid = character:findFirstChild("Humanoid")

        if humanoid then

            humanoid.Changed:connect(function(property)

                if humanoid.Jump == true then

                    humanoid.Jump = false

                    humanoid.Sit = false

                   humanoid.PlatformStand = false

                end

            end)
        end
   end
end)

Thats the basics of explaining Hope this helped:D Let Me know I can Simplify it Even More if its to confusing. Or if it doesnt work I can fix it and explain how I fixed it.

2
or just set "JumpPower" to 0. lol lukeb50 631 — 8y
0
though the same thing XD HALTDEINMAULDUDEN 5 — 7y
Ad

Answer this question