function onTouched(h)local k=h.Parent:findFirstChild("\072\117\109\097\110\111\105\100")if k~=nil then tagHumanoid(k)k.Health=k.Health-10 untagHumanoid(k)connection:disconnect()else damage=damage/2 if damage<2 then connection:disconnect()ball.Parent=nil end end if math.random(1,2)==1 then explosion=Instance.new("\069\120\112\108\111\115\105\111\110")explosion.BlastRadius=5 explosion.BlastPressure=50000 explosion.Position=script.Parent.Position explosion.Parent=game.Workspace connection:disconnect()ball.Parent=nil end end function tagHumanoid(h)local k=ball:findFirstChild("\099\114\101\097\116\111\114")if k~=nil then local W=k:clone()W.Parent=h end end function untagHumanoid(h)if h~=nil then local k=h:findFirstChild("\099\114\101\097\116\111\114")if k~=nil then k.Parent=nil end end end connection=ball.Touched:connect(onTouched)r=game:service("\082\117\110\083\101\114\118\105\099\101")t,s=r.Stepped:wait()d=(t+5.0)-s while t<d do t=r.Stepped:wait()end ball.Parent=nil

function onTouched(hit)


	local humanoid = hit.Parent:findFirstChild("Humanoid")
	if humanoid~=nil then
		tagHumanoid(humanoid)
		humanoid.Health = humanoid.Health - 10
		untagHumanoid(humanoid)
		connection:disconnect()
	else
		damage = damage / 2
		if damage < 2 then
			connection:disconnect()
			ball.Parent = nil
		end
	end

	if math.random(1,2) == 1 then
		explosion = Instance.new("Explosion")
		explosion.BlastRadius = 5
		explosion.BlastPressure = 50000 -- these are really wussy units
		explosion.Position = script.Parent.Position
		explosion.Parent = game.Workspace
		connection:disconnect()
		ball.Parent = nil

	end

end

function tagHumanoid(humanoid)
	-- todo: make tag expire
	local tag = ball:findFirstChild("creator")
	if tag ~= nil then
		local new_tag = tag:clone()
		new_tag.Parent = humanoid
	end
end


function untagHumanoid(humanoid)
	if humanoid ~= nil then
		local tag = humanoid:findFirstChild("creator")
		if tag ~= nil then
			tag.Parent = nil
		end
	end
end

connection = ball.Touched:connect(onTouched)

r = game:service("RunService")
t, s = r.Stepped:wait()
d = t + 5.0 - s
while t < d do
	t = r.Stepped:wait()
end

ball.Parent = nil
