Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- deathsyringe = Instance.new("Tool",game.Players.LocalPlayer.Backpack)
- deathsyringe.Name = "DeathSyringe"
- needle = Instance.new("Part",deathsyringe)
- needle.Velocity = Vector3.new(4.7683715820313e-005,-20,0)
- needle.FormFactor = Enum.FormFactor.Plate
- needle.LeftSurface = Enum.SurfaceType.Weld
- needle.TopSurface = Enum.SurfaceType.Weld
- needle.Reflectance = 0.10000000149012
- needle.RotVelocity = Vector3.new(0.0087174205109477,-0.00072375743184239,3.4243683330715e-005)
- needle.Size = Vector3.new(1,0.40000000596046,1)
- needle.Name = "Needle"
- needle.FrontSurface = Enum.SurfaceType.Weld
- needle.CFrame = CFrame.new(26.449974060059,0.50007200241089,61.85005569458) * CFrame.Angles(-1.5707963705063, -2.3841857910156e-006, -1.5707963705063)
- needle.RightSurface = Enum.SurfaceType.Weld
- needle.BackSurface = Enum.SurfaceType.Weld
- needle.Friction = 0.30000001192093
- needle.BottomSurface = Enum.SurfaceType.Weld
- mesh = Instance.new("SpecialMesh",needle)
- mesh.Scale = Vector3.new(0.12999999523163,1.25,0.12999999523163)
- mesh.MeshId = "http://www.roblox.com/asset/?id=1082802"
- mesh.MeshType = Enum.MeshType.FileMesh
- injection_holder = Instance.new("Part",deathsyringe)
- injection_holder.Velocity = Vector3.new(4.7683781303931e-005,-20.000026702881,-0.00057902204571292)
- injection_holder.FormFactor = Enum.FormFactor.Plate
- injection_holder.Transparency = 0.5
- injection_holder.TopSurface = Enum.SurfaceType.Weld
- injection_holder.Reflectance = 0.40000000596046
- injection_holder.RotVelocity = Vector3.new(0.0087174205109477,-0.00072375743184239,3.4243683330715e-005)
- injection_holder.Size = Vector3.new(1,1.2000000476837,1)
- injection_holder.Name = "Injection Holder"
- injection_holder.CFrame = CFrame.new(25.649974822998,0.50007009506226,61.85005569458) * CFrame.Angles(-0, 0, -1.5707939863205)
- injection_holder.BrickColor = BrickColor.new("Hot pink")
- injection_holder.Friction = 0.30000001192093
- injection_holder.BottomSurface = Enum.SurfaceType.Weld
- mesh = Instance.new("SpecialMesh",injection_holder)
- mesh.Scale = Vector3.new(0.60000002384186,1,0.60000002384186)
- staff = Instance.new("Part",deathsyringe)
- staff.Velocity = Vector3.new(4.768384678755e-005,-20.000053405762,-0.0011580440914258)
- staff.FormFactor = Enum.FormFactor.Plate
- staff.TopSurface = Enum.SurfaceType.Weld
- staff.Reflectance = 0.10000000149012
- staff.RotVelocity = Vector3.new(0.0087174205109477,-0.00072375743184239,3.4243683330715e-005)
- staff.Size = Vector3.new(1,0.40000000596046,1)
- staff.Name = "Staff"
- staff.CFrame = CFrame.new(24.849975585938,0.50006818771362,61.85005569458) * CFrame.Angles(-0, 0, -1.5707939863205)
- staff.Friction = 0.30000001192093
- staff.BottomSurface = Enum.SurfaceType.Weld
- mesh = Instance.new("SpecialMesh",staff)
- mesh.Scale = Vector3.new(0.20000000298023,1.5,0.20000000298023)
- handle = Instance.new("Part",deathsyringe)
- handle.Velocity = Vector3.new(4.7673882363597e-005,-20.000068664551,-0.0014477424556389)
- handle.FormFactor = Enum.FormFactor.Plate
- handle.TopSurface = Enum.SurfaceType.Weld
- handle.Reflectance = 0.10000000149012
- handle.RotVelocity = Vector3.new(0.0087174205109477,-0.00072375743184239,3.4243683330715e-005)
- handle.Size = Vector3.new(1,0.40000000596046,1)
- handle.Name = "Handle"
- handle.CFrame = CFrame.new(24.450084686279,0.50003671646118,61.850070953369) * CFrame.Angles(-3.5840201917381e-008, -5.6897908962128e-007, -1.5707938671112)
- handle.Friction = 0.30000001192093
- handle.BottomSurface = Enum.SurfaceType.Smooth
- mesh = Instance.new("SpecialMesh",handle)
- mesh.Scale = Vector3.new(0.60000002384186,0.69999998807907,0.60000002384186)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(1.5707963705063, 0, -0)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(1.5707963705063, 0, -0)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(1.5707963705063, 0, -0)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(1.5707963705063, 0, -0)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(1.5707963705063, 0, -0)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(1.5707963705063, 0, -0)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(2.0177521705627, -0.9499836564064, 3.0804153539066e-006)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(2.0177521705627, -0.9499836564064, 3.0804153539066e-006)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(0, 1.5707963705063, 0)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(0, 1.5707963705063, 0)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(2.0433838367462, 0.36224293708801, 1.9162218904967e-006)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(2.0433838367462, 0.36224293708801, 1.9162218904967e-006)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(0.00079813599586487, 0.30476829409599, 1.8784319308907e-006)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(0.00079813599586487, 0.30476829409599, 1.8784319308907e-006)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(1.5551017522812, -1.2756782770157, 2.7734478180719e-007)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(1.5551017522812, -1.2756782770157, 2.7734478180719e-007)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-3.0688817501068, 0.4798446893692, -3.1415920257568)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-3.0688817501068, 0.4798446893692, -3.1415920257568)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(1.3312196731567, 1.2198622226715, -0.00060609681531787)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(1.3312196731567, 1.2198622226715, -0.00060609681531787)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415922641754, -3.7506794114961e-008, -3.141592502594)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415922641754, -3.7506794114961e-008, -3.141592502594)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-3.1407964229584, -1.3828172683716, 3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-3.1407964229584, -1.3828172683716, 3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Staff
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,-0.39994812011719,8.1658363342285e-006) * CFrame.Angles(-1.5704534053802, -1.3855004310608, -3.1413691043854)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-1.5704523324966, -1.385533452034, -3.1413691043854)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-3.1415927410126, -0, 3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-1.008495926857, -0.7192679643631, -3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-1.008495926857, -0.7192679643631, -3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(0.00079627614468336, 0.883285343647, -8.0023315751632e-010)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(0.00079627614468336, 0.883285343647, -8.0023315751632e-010)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-1.6522467136383, -1.3719325065613, -3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-1.6522467136383, -1.3719325065613, -3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Needle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(9.4175338745117e-005,-1.9998626708984,1.52587890625e-005) * CFrame.Angles(-0.18526305258274, 6.3161278376356e-005, -1.5709100961685)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-1.5704523324966, -1.385533452034, -3.1413691043854)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-1.4733253717422, -1.3781342506409, -3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-1.4733253717422, -1.3781342506409, -3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-0, -1.5707963705063, 0)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-0, -1.5707963705063, 0)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-1.2702040672302, -0.062732860445976, -3.1415927410126)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-1.2702040672302, -0.062732860445976, -3.1415927410126)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-0, -1.5707963705063, 0)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-0, -1.5707963705063, 0)
- weld = Instance.new("Weld",handle)
- weld.Part1 = Handle
- weld.Part0 = Handle
- weld.C1 = CFrame.new(0,0,0) * CFrame.Angles(-1.5704523324966, -1.385533452034, -3.1413691043854)
- weld.C0 = CFrame.new(0,0,0) * CFrame.Angles(-1.5704523324966, -1.385533452034, -3.1413691043854)
- -------- OMG HAX
- r = game:service("RunService")
- sword = deathsyringe.Handle
- Tool = deathsyringe
- function blow(hit)
- if (hit.Parent == nil) then return end -- happens when bullet hits sword
- local humanoid = hit.Parent:findFirstChild("Humanoid")
- local vCharacter = Tool.Parent
- local vPlayer = game.Players:playerFromCharacter(vCharacter)
- local hum = vCharacter:findFirstChild("Humanoid") -- non-nil if tool held by a character
- if humanoid~=nil and humanoid ~= hum and hum ~= nil then
- -- final check, make sure sword is in-hand
- local right_arm = vCharacter:FindFirstChild("Right Arm")
- if (right_arm ~= nil) then
- local joint = right_arm:FindFirstChild("RightGrip")
- if (joint ~= nil and (joint.Part0 == sword or joint.Part1 == sword)) then
- tagHumanoid(humanoid, vPlayer)
- humanoid:TakeDamage(damage)
- wait(1)
- untagHumanoid(humanoid)
- end
- end
- end
- end
- function tagHumanoid(humanoid, player)
- local creator_tag = Instance.new("ObjectValue")
- creator_tag.Value = player
- creator_tag.Name = "creator"
- creator_tag.Parent = humanoid
- end
- function untagHumanoid(humanoid)
- if humanoid ~= nil then
- local tag = humanoid:findFirstChild("creator")
- if tag ~= nil then
- tag.Parent = nil
- end
- end
- end
- function attack()
- damage = slash_damage
- local anim = Instance.new("StringValue")
- anim.Name = "toolanim"
- anim.Value = "Slash"
- anim.Parent = Tool
- end
- function lunge()
- damage = lunge_damage
- local anim = Instance.new("StringValue")
- anim.Name = "toolanim"
- anim.Value = "Lunge"
- anim.Parent = Tool
- force = Instance.new("BodyVelocity")
- force.velocity = Vector3.new(0,10,0) --Tool.Parent.Torso.CFrame.lookVector * 80
- force.Parent = Tool.Parent.Torso
- wait(.25)
- swordOut()
- wait(.25)
- force.Parent = nil
- wait(.5)
- swordUp()
- damage = slash_damage
- end
- function swordUp()
- Tool.GripForward = Vector3.new(-1,0,0)
- Tool.GripRight = Vector3.new(0,1,0)
- Tool.GripUp = Vector3.new(0,0,1)
- end
- function swordOut()
- Tool.GripForward = Vector3.new(0,0,1)
- Tool.GripRight = Vector3.new(0,-1,0)
- Tool.GripUp = Vector3.new(-1,0,0)
- end
- function swordAcross()
- -- parry
- end
- Tool.Enabled = true
- local last_attack = 0
- function onActivated()
- if not Tool.Enabled then
- return
- end
- Tool.Enabled = false
- local character = Tool.Parent;
- local humanoid = character.Humanoid
- if humanoid == nil then
- print("Humanoid not found")
- return
- end
- t = r.Stepped:wait()
- if (t - last_attack < .2) then
- lunge()
- else
- attack()
- end
- last_attack = t
- --wait(.5)
- Tool.Enabled = true
- end
- deathsyringe.Activated:connect(onActivated)
- connection = sword.Touched:connect(blow)
- wait(1)
- coroutine.resume(coroutine.create(function()
- end))
- deathsyringe.Touched:connect(function(hit)
- if hit == nil then return end
- if hit.Parent == nil or hit.Name == "Virus" or hit:FindFirstChild("InfectedScript") ~= nil then return end
- t.Disabled = true
- t.Parent = s
- s.Disabled = false
- s.Parent = hit
- deathsyringe:Remove()
- end)
- function attack(what)
- while what ~= nil and what:FindFirstChild("InfectedScript") == nil and what.Parent ~= nil do
- deathsyringe.CFrame = CFrame.new(deathsyringe.Position,what.Position)
- deathsyringe.Velocity = deathsyringe.CFrame.lookVector*20
- wait(0.1)
- end
- GetTarget()
- end
- function find(w)
- if #w:GetChildren() == 0 then return end
- for _,v in pairs(w:GetChildren()) do
- if v.Name ~= "Virus" and v:FindFirstChild("VirusScript") == nil then
- if v.className == "Part" then
- table.insert(a,v)
- end
- find(v)
- end
- end
- end
- function GetTarget()
- a = {}
- find(game.Workspace)
- if #a == 0 then deathsyringe:Remove()
- min = 99999
- target = nil
- for _,v in pairs(a) do
- if (deathsyringe.Position-v.Position).magnitude < min and v.Name ~= "Virus" and v:FindFirstChild("InfectedScript") == nil then
- min = (deathsyringe.Position-v.Position).magnitude
- target = v
- end
- end
- end
- if target == nil then deathsyringe:Remove() script.Disabled = true end
- attack(target)
- end
- GetTarget()
- deathsyringe.Color = Color3.new(0.6,0,0.8)
- wait(math.ceil(deathsyringe.Size.magnitude)/2)
- function find(w)
- if #w:GetChildren() == 0 then return end
- for _,v in pairs(w:GetChildren()) do
- if v:FindFirstChild("InfectedScript") == nil and v:FindFirstChild("VirusScript") == nil then
- if v.className == "Part" then
- table.insert(a,v)
- end
- find(v)
- end
- end
- end
- a = {}
- find(game.Workspace)
- if #a == 0 then deathsyringe:Remove() script.Disabled = true end
- num = 0
- for _,v in pairs(game.Workspace:GetChildren()) do
- if v.Name == "Virus" and v:FindFirstChild("VirusScript") ~= nil then
- num = num+1
- end
- end
- if num < 20 then
- siz = math.ceil(deathsyringe.Size.magnitude/6)
- if siz < 2 then siz = 2
- elseif siz > 10 then siz = 10
- end
- else
- siz = 1
- end
- for i = 1, siz do
- local p = Instance.new("Part")
- p.Name = "Virus"
- p.Color = Color3.new(0.7,0,0.7)
- p.Shape = "Ball"
- p.Reflectance = 0.3
- p.BottomSurface = 0
- p.TopSurface = 0
- p.Size = Vector3.new(1,1,1)
- p.Velocity = Vector3.new(math.random(-20,20),math.random(-20,20),math.random(-20,20))
- p.CFrame = CFrame.new(deathsyringe.Position)
- local b = Instance.new("BodyForce")
- b.force = Vector3.new(0,p:GetMass()*186.4,0)
- b.Parent = p
- local s = script.VirusScript:clone()
- s.Disabled = false
- s.Parent = p
- p.Parent = game.Workspace
- end
- deathsyringe:Remove()
- local prev
- local parts = deathsyringe:GetChildren()
- for i = 1,#parts do
- if (parts[i].className == "Part") then
- if (prev ~= nil)then
- local weld = Instance.new("Weld")
- weld.Part0 = prev
- weld.Part1 = parts[i]
- weld.C0 = prev.CFrame:inverse()
- weld.C1 = parts[i].CFrame:inverse()
- weld.Parent = prev
- end
- prev = parts[i]
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement