script.Parent.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
local player = game.Players:GetPlayerFromCharacter(hit.Parent)
local descendants = player.Character:GetDescendants()
if player ~= nil then
for index, descendant in pairs(descendants) do
if descendant:IsA("BasePart") and ("Decal") and descendant ~= player.Character.HumanoidRootPart then
descendant.Transparency = 1
end
end
local scriptt = game.ReplicatedStorage.Scrapt:Clone()
scriptt.Parent = player.Character
wait(11)
scriptt:Destroy()
for index, descendant in pairs(descendants) do
if descendant:IsA("BasePart") and ("Decal") and descendant ~= player.Character.HumanoidRootPart then
descendant.Transparency = 0
end
end
end
end
end)
so basically when i hit a part i want it to copy a script but it copys it alot of times and ruining the actual mecanique so idk wat to do

1 comment
add a debounce