local player = game.Players.LocalPlayer local character = player.Character local UIS = game:GetService("UserInputService") if not character or not character.Parent then character = player.CharacterAdded:wait() end UIS.InputBegan:Connect(function(input) if input.KeyCode == Enum.KeyCode.F then game.Players.PlayerAdded:Connect(function(player) player.CharacterAdded:Connect(function(character) character.Humanoid.WalkSpeed = 130 end) end
I tested this and it should work. if its in a Local Script in StarterGui .
local player = game.Players.LocalPlayer local character = player.Character local UIS = game:GetService("UserInputService") UIS.InputBegan:Connect(function(input) if input.KeyCode == Enum.KeyCode.F then character.Humanoid.WalkSpeed = 130 end end)