I am making a game with changing walkspeed but it isnt working properly. This is the code:
local Player = game.Players.LocalPlayer
humanoid = script.Parent:WaitForChild("Humanoid")
function antispeedhack()
if humanoid.WalkSpeed ~= 25 then
local remoteevent = game.ReplicatedStorage:WaitForChild("Kick")
remoteevent:FireServer("Kick")
end
end
humanoid.WalkSpeed.Changed:connect(antispeedhack)

4 comments
try chaging _G.Play into (_G.Play.Value == true) in lines 15 and 18
@naturewizard when I do that I get "attempt to index field "Play" (a boolean value)"
Oh sorry, try making it (_G.Play == true) in lines 15 and 18
Thank you it works. :)