local debounce = 0
local players = game:GetService("Players")
local player = players.LocalPlayer
local char = player.Character or player.CharacterAdded:Wait()
local hum = char:WaitForChild("Humanoid")
if debounce == 0 then
if script.Parent.Value == "SkyForge" then
hum.WalkSpeed += 8
end
debounce = 1
end
the script above is not working. Note: The value is changing, The Walkspeed is set to the default (16).
@NetheriteMc_Q I dont really know what your script does, but here’s a fixed one.
local player = game:GetService("Players").LocalPlayer
local Character = player.Character or player.CharacterAdded:Wait()
local value = script.Parent.Value
local humanoid = Character:WaitForChild("Humanoid")
local debounce = 0
local debounceTime = 3
value.Changed:Connect(function()
if value.Value == "SkyForge" and debounce == 0 then
humanoid.WalkSpeed += 8 -- amount of speed added
debounce = 1
end
wait(debounceTime)
debounce = 0
end)
local players = game:GetService("Players")
local function ChangeWalkSpeed(Player)
if script.Parent.Value == "SkyForge" then
Player.CharacterAdded:Connect(function(Character)
local Humanoid = Character:WaitForChild("Humanoid")
Humanoid.WalkSpeed += 8
end)
end
end
players.PlayerAdded:Connect(ChangeWalkSpeed)
Make sure the StrValue is the parent of this serverScript
local player = game:GetService("Players").LocalPlayer
local Character = player.Character or player.CharacterAdded:Wait()
local value = script.Parent.Value
local humanoid = Character:WaitForChild("Humanoid")
local debounce = 0
value.Changed:Connect(function()
if value.Value == "SkyForge" and debounce < 3 then
humanoid.WalkSpeed += 8 -- amount of speed added
debounce += 1
end
end)
local player = game:GetService("Players").LocalPlayer
local Character = player.Character or player.CharacterAdded:Wait()
local value = script.Parent.Value
local humanoid = Character:WaitForChild("Humanoid")
local count = 0
local maxCount = 1
changed = value.Changed:Connect(function()
if value.Value == "SkyForge" and count <= maxCount then
humanoid.WalkSpeed += 8 -- amount of speed added
count += 1
end
if count == maxCount then
changed:Disconnect()
end
end)