so i tried making an item that heals and increaces the walkspeed, but it seems to not work local CanActivate = true local player = game.Players.LocalPlayer local character = player.Character
script.Parent.Activated:Connect(function() if CanActivate == true then CanActivate = false local animation = character.Humanoid:LoadAnimation(script.Parent.Animation) animation:Play() wait(1) character.Humanoid.Health = character.Humanoid.MaxHealth character.Humanoid.Walkspeed = Humanoid.WalkSpeed + 10 wait(1) wait(60) CanActivate = true end end)
If I'm not mistaken, I believe that you were missing "character" and "Walkspeed" is supposed to be spelt "WalkSpeed" in this line:
character.Humanoid.WalkSpeed = character.Humanoid.WalkSpeed + 10
local CanActivate = true local player = game.Players.LocalPlayer local character = player.Character script.Parent.Activated:Connect(function() if CanActivate == true then CanActivate = false local animation = character.Humanoid:LoadAnimation(script.Parent.Animation) animation:Play() wait(1) character.Humanoid.Health = character.Humanoid.MaxHealth character.Humanoid.Walkspeed = character.Humanoid.WalkSpeed + 10 wait(1) wait(60) CanActivate = true end end)