HumanoidStateEnabled not replicating to the client

Hello developers, while trying to limit the player from jumping on the server by changing their HumanoidStateEnabled I figured it would also replicate to the client by default and limit them, but after setting it to false and printing the HumanoidStateEnabled on the client it was matter of fact true but remains false on the server, and the player’s ability to jump depends on the value that is on the client

What do you think seems to be the issue?

-- Server
local Player = -- define player
local Character = Player.Character or Player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")

Humanoid:SetEnabledState(Enum.HumanoidStateType.Jumping, false)
print(Humanoid:GetStateEnabled(Enum.HumanoidStateType.Jumping)) -- false

-- Client
local Player = -- define player
local Character = Player.Character or Player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")

print(Humanoid:GetStateEnabled(Enum.HumanoidStateType.Jumping)) -- true

Have you considered just setting the CharacterJumpPower to 0?

I have found an alternative, I’m just wondering why HumanoidState doesn’t replicate

No specific answer has been found to this problem but it was reported back in 2019 with no answers until now, it’s either Roblox hasn’t viewed this or it was somehow intended

Only a Roblox engineer can answer this question, currently

1 Like