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

How do you prevent jumping?

Asked by 10 years ago

I know for a fact that there is a way to prevent jumping, but I can't figure it out. I have tried BodyObjects, Changed events, and other methods, but I'm stumped. All help is appreciated!

1 answer

Log in to vote
0
Answered by
Redbullusa 1580 Moderation Voter
10 years ago

How I usually do it is by the Changed event and it worked for me.

Humanoid = game.Players.LocalPlayer.Character:FindFirstChild("Humanoid")

Humanoid.Changed:connect(function ()
    Humanoid.Jump = false
end
0
I have tried this before, but it only works on Play Solo. I need something that works on a server. User#348 0 — 10y
1
you might want to add a line or 2 that waits for the character tumadrina 179 — 10y
0
This was just an example code, so I will only code what's given from the question. Yes, you might want to consider to have the script to pause its thread until the character is fully rendered. Redbullusa 1580 — 10y
1
Such as 'repeat wait() until game.Players.LocalPlayer' or some other such variations. Redbullusa 1580 — 10y
Ad

Answer this question