repeat wait() Player = game.Players.LocalPlayer until (Player) and (Player.Character) Player:WaitForChild("leaderstats").Streak.Changed:connect(function() if Player.leaderstats.Streak.Value >= 1 then game.ReplicatedStorage.AC130:Clone().Parent = Player.Backpack end end)
This is the code, I can't find the problem
Just use this, a lot of times using repeat and :WaitForChild() glitch:
local Player = game.Players.LocalPlayer local ToolName = "AC130" --Put the name of the tool here Player.CharacterAdded:wait() wait(1) Player.leaderstats.Streak.Changed:connect(function(value) if value >= 1 then if not Player.Backpack:FindFirstChild(ToolName) then game.ReplicatedStorage[ToolName]:Clone().Parent = Player.Backpack end end end)