Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- arrow = script.Parent
- damage = 80
- en = true
- function onTouched(hit)
- if en == true then
- en = false
- if hit.Parent:findFirstChild("Humanoid") then
- hit.Parent:findFirstChild("Humanoid").Health = hit.Parent:findFirstChild("Humanoid").Health - 20
- local d = Instance.new("Part")
- d.Parent = game.Workspace
- d.CanCollide = false
- script.Parent.Mesh.Script:remove()
- script.Parent.Anchored = true
- d.CFrame = hit.CFrame
- d.Size = Vector3.new(8,8,8)
- d.Shape = "Ball"
- d.BrickColor = BrickColor.new("Really black")
- d.CanCollide = false
- local t = Instance.new("BodyPosition")
- t.maxForce = Vector3.new(1000000000000000000000000000000,1000000000000000000000000000000,1000000000000000000000000000000)
- t.position = hit.Position
- wait(0.1)
- t.Parent = d
- wait(1)
- d:remove()
- script.Parent:remove()
- else
- script.Parent:remove()
- end
- wait(20000)
- en = true
- else
- end
- end
- function tagHumanoid(humanoid)
- -- todo: make tag expire
- local tag = arrow: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 = arrow.Touched:connect(onTouched)
- r = game:service("RunService")
- t, s = r.Stepped:wait()
- d = t + 10.0 - s
- while t < d do
- t = r.Stepped:wait()
- end
- arrow.Parent = nil
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement