Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local plr = owner
- local char = plr.Character
- local hum = char:FindFirstChildOfClass("Humanoid")
- local torso = char['Torso'] or char['UpperTorso']
- Tool0 = Instance.new("Tool")
- Part1 = Instance.new("Part")
- SpecialMesh2 = Instance.new("SpecialMesh")
- Sound3 = Instance.new("Sound")
- Sound4 = Instance.new("Sound")
- Tool0.Name = "Taser"
- Tool0.CanBeDropped = false
- Tool0.ToolTip = "taser them skids"
- Tool0.TextureId = "rbxassetid://517843292"
- Tool0.Parent = plr.Backpack
- Part1.Name = "Handle"
- Part1.Parent = Tool0
- Part1.CFrame = CFrame.new(-17.4752846, 1.57726252, 10.3508625, 0.152027637, -0.454833627, -0.877504945, 1.38640985e-07, 0.887824535, -0.460182667, 0.988376021, 0.069960326, 0.134974062)
- Part1.Orientation = Vector3.new(27.3999996, -81.2600021, 0)
- Part1.Position = Vector3.new(-17.4752846, 1.57726252, 10.3508625)
- Part1.Rotation = Vector3.new(73.6500015, -61.3400002, 71.5199966)
- Part1.Color = Color3.new(0.105882, 0.164706, 0.207843)
- Part1.Size = Vector3.new(1, 2.10799956, 2.7879982)
- Part1.BottomSurface = Enum.SurfaceType.Smooth
- Part1.BrickColor = BrickColor.new("Black")
- Part1.Locked = true
- Part1.TopSurface = Enum.SurfaceType.Smooth
- Part1.brickColor = BrickColor.new("Black")
- Part1.FormFactor = Enum.FormFactor.Custom
- Part1.formFactor = Enum.FormFactor.Custom
- SpecialMesh2.Parent = Part1
- SpecialMesh2.MeshId = "http://www.roblox.com/asset/?id=82337638"
- SpecialMesh2.TextureId = "http://www.roblox.com/asset/?id=82337709"
- SpecialMesh2.MeshType = Enum.MeshType.FileMesh
- Sound3.Name = "EquippedSound"
- Sound3.Parent = Part1
- Sound3.EmitterSize = 1
- Sound3.SoundId = "rbxassetid://138244068"
- Sound3.Volume = 5
- Sound4.Name = "FireSound"
- Sound4.Parent = Part1
- Sound4.Looped = true
- Sound4.EmitterSize = 1
- Sound4.SoundId = "rbxassetid://277635663"
- Sound4.Volume = 10
- FlangeSoundEffect0 = Instance.new("FlangeSoundEffect",Sound4)
- FlangeSoundEffect0.Rate = 10
- FlangeSoundEffect0.Depth = 0.5
- FlangeSoundEffect0.Mix = 1
- FlangeSoundEffect1 = Instance.new("FlangeSoundEffect",Sound3)
- FlangeSoundEffect1.Rate = 10
- FlangeSoundEffect1.Depth = 1
- FlangeSoundEffect1.Mix = 1
- local tool = Tool0
- local handle = Part1
- local debris = game:GetService("Debris")
- local tween = game:GetService("TweenService")
- local using = false
- local equipped = false
- function tase(hitbox)
- local connection
- connection = hitbox.Touched:Connect(function(obj)
- local hum = obj.Parent:FindFirstChildOfClass("Humanoid")
- local targchar = obj.Parent
- if obj and targchar and hum and hum.Parent and targchar ~= char and targchar.ClassName == "Model" and not targchar:FindFirstChild("got taser phasered") then
- local confirm = Instance.new("IntValue")
- confirm.Parent = targchar
- confirm.Name = "got taser phasered"
- local tasing = true
- spawn(function()
- wait(2)
- tasing = false
- confirm:Destroy()
- end)
- spawn(function()
- while targchar and targchar.Parent and tasing do
- if math.random(1,2) == 1 then
- if hum then
- hum.Sit = true
- end
- else
- if hum then
- hum.Sit = false
- end
- end
- wait()
- hum.WalkSpeed = 0
- for i,v in pairs(targchar:GetDescendants()) do
- if v:IsA("Part") or v:IsA("MeshPart") or v:IsA("UnionOperation") or v:IsA("BasePart") then
- v.CFrame = v.CFrame * CFrame.Angles(math.rad(math.random(-20,20)/10),math.rad(math.random(-20,20)/10),math.rad(math.random(-20,20)/10))
- v.Rotation = v.Rotation * math.random(-2,2) --(math.random(-10,10)/10)
- end
- end
- end
- --[[
- spawn(function()
- while targchar do
- wait()
- if hum then
- hum.MaxHealth = 0
- hum.Health = 0
- end
- if targchar then
- targchar:BreakJoints()
- end
- end
- end)
- ]]
- end)
- end
- end)
- wait(5)
- connection:Disconnect()
- end
- tool.Equipped:Connect(function()
- equipped = true
- Sound3:Play()
- end)
- tool.Unequipped:Connect(function()
- equipped = false
- Sound3:Stop()
- end)
- Tool0.Activated:Connect(function()
- if equipped and not using then
- using = true
- Sound4:Play()
- tase(Part1)
- Sound4:Stop()
- using = false
- end
- end)
Add Comment
Please, Sign In to add comment