So yesterday i asked why it would give tools to everyone. Now it gives infinite tools??
no i don't want any link. Just give me the script and explain
Here's the script:
local Part = game.Workspace.BuyPart
local RS = game:GetService("ReplicatedStorage")
local Sword = RS.Tools:FindFirstChild("SpeedCoil")
local Players = game:GetService("Players")
Part.Touched:Connect(function(hit)
local Player = game.Players:GetPlayerFromCharacter(hit.Parent)
if Player.leaderstats.Points.Value >= 500 then
local SwordClone = Sword:Clone()
SwordClone.Parent = Player.Backpack
end
local GravityCoil = RS.Tools:FindFirstChild("GravityCoil")
local Part1 = game.Workspace.BuyPart1
Part1.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
if Player.leaderstats.Points.Value >= 7000 then
local CoilClone = GravityCoil:Clone()
CoilClone.Parent = Player.Backpack
end
local Part2 = game.Workspace.BuyPart2
local Tool = RS.Tools:FindFirstChild("PointGiverTool")
Part2.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
if Player.leaderstats.Points.Value >= 10000 then
local ToolClone = Tool:Clone()
ToolClone.Parent = Player.Backpack
end
end
end)
end
end)
end)
Thanks.

3 comments
I'm too lazy to write your script, but after the if statement to check if they have enough points check if there is an item named like your item you will give them already in the backpack.
okay nice
i do not understand what you mean.. at all