I just accidentaly deleted my edit, but anyways, this is a spill system and whenever it comes into contact with a mop, it won’t mop it up, any thoughts why? There’s no spelling errors in the mop name, the script:
local spill = script.Parent
local goal = {}
goal.Size = spill.Size - Vector3.new(0,5,5)
local tweenInfo = TweenInfo.new(5)
local tween = TweenService:Create(spill, tweenInfo, goal)
local activated = false
game.Players.PlayerAdded:Connect(function(player)
spill.Touched:Connect(function(hit)
if hit.Parent.Name == "Mop" then
if activated == false then
activated = true
if spill.Transparency == 0 then
tween:Play()
wait(5)
spill.Transparency = 1
spill.Size = Vector3.new(0.05, 5.375, 5.375)
player.leaderstats.Points.Value += 1
end
activated = false
end
end
end)
end)