This script is inside a turrent.
ball = script.Parent
damage = 50
function onTouched(hit)
local humanoid = hit.Parent:findFirstChild("Humanoid")
if humanoid ~= nil then
humanoid:TakeDamage(damage)
ball:Remove()
end
end
connection = ball.Touched:connect(onTouched)
wait(5)
ball.Parent = nil

3 comments
Your script did not work. I think you need to tell the script where the explosion will happen...
You need to actually parent it to the ball after TakeDamage, or use "Explosion", parentofexplosion instead of "Explosion" in Instance.new
Check the edit I posted, it goes in more depth.