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