Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local billboard = Instance.new("ScreenGui", owner.PlayerGui)
- local cloakmeter = Instance.new("Frame",billboard)
- cloakmeter.BackgroundColor3 = Color3.fromRGB(130, 130, 130)
- cloakmeter.Size = UDim2.new(0.25,0,0.075,0)
- cloakmeter.AnchorPoint = Vector2.new(0.15, 0.95)
- cloakmeter.Position = UDim2.new(0.15, 0, 0.95, 0)
- cloakmeter.Active = true
- cloakmeter.Transparency = 0.4
- local cloakmeter2 = Instance.new("Frame",cloakmeter)
- cloakmeter2.Size = UDim2.new(1,0,1,0)
- cloakmeter2.BackgroundColor3 = Color3.fromRGB(10,240,10)
- cloakmeter2.Transparency = 0.4
- local cloakmeter3 = Instance.new("Frame",cloakmeter)
- cloakmeter3.Size = UDim2.new(0,0,1,0)
- cloakmeter3.BackgroundColor3 = Color3.fromRGB(50,50,50)
- cloakmeter3.AnchorPoint = Vector2.new(1, 0)
- cloakmeter3.Position = UDim2.new(1, 0, 0, 0)
- cloakmeter3.Transparency = 0.4
- local round = Instance.new("UICorner",cloakmeter)
- round.CornerRadius = UDim.new(0.1)
- local round = Instance.new("UICorner",cloakmeter2)
- round.CornerRadius = UDim.new(0.1)
- local round = Instance.new("UICorner",cloakmeter3)
- round.CornerRadius = UDim.new(0.1)
- local old = owner.Character.Humanoid.Health
- local harddamage = 0
- local time = 10
- coroutine.wrap(function()
- while task.wait() do
- pcall(function()
- cloakmeter3.Size = UDim2.new(math.clamp(harddamage,0.1,99)/100,0,1,0)
- cloakmeter2.Size = UDim2.new(owner.Character.Humanoid.Health/owner.Character.Humanoid.MaxHealth,0,1,0)
- end)
- end
- end)()
- coroutine.wrap(function()
- pcall(function()
- while owner.Character.Humanoid.Health > 0 do
- repeat
- wait(0.1)
- time -= 0.1
- until time <= 0
- harddamage = math.clamp(harddamage - (5),0,99)
- time = time + 0.1
- end
- end)
- end)()
- owner.Character.Humanoid:GetPropertyChangedSignal("MaxHealth"):Connect(function(wha)
- if wha ~= 100 then
- harddamage = math.clamp(harddamage + (100 - wha),0,99)
- owner.Character.Humanoid.MaxHealth = 100
- end
- end)
- owner.Character.Humanoid.HealthChanged:Connect(function(newhealth)
- pcall(function()
- if newhealth < old then
- time = 10
- harddamage = math.clamp(harddamage + ((old - newhealth) * 0.2),0,99)
- old = newhealth
- elseif newhealth > old then
- old = newhealth
- end
- end)
- end)
- if owner.Character:FindFirstChild("Health") then
- owner.Character:FindFirstChild("Health"):Destroy()
- end
- local rayblacklist = {}
- local p = Instance.new("SpawnLocation")
- p.Enabled = false
- p.Transparency = 1
- p.Size = Vector3.new(0.25,0.25,0.25)
- p.Name = "bloodyhujijahuyugtfvfyh"
- local attachment0 = Instance.new("Attachment",p)
- local attachment1 = Instance.new("Attachment",p)
- attachment1.CFrame = CFrame.new(-0.1,0.1,0.1)
- attachment0.CFrame = CFrame.new(0.1,-0.1,-0.1)
- local trail = Instance.new("Trail",p)
- trail.Attachment0 = attachment0
- trail.Attachment1 = attachment1
- trail.Lifetime = 0.15
- trail.Transparency = NumberSequence.new{NumberSequenceKeypoint.new(0, 0.2),NumberSequenceKeypoint.new(1, 1)}
- trail.WidthScale = NumberSequence.new{NumberSequenceKeypoint.new(0, 1),NumberSequenceKeypoint.new(1, 0)}
- trail.MaxLength = 0
- trail.LightEmission = 0
- trail.LightInfluence = 1
- trail.TextureLength = 1
- trail.TextureMode = "Stretch"
- trail.Color = ColorSequence.new(Color3.fromRGB(85,0,0))
- trail.MinLength = 0.1
- trail.FaceCamera = true
- local min = -15
- local max = 15
- function splat(whatpart,times)
- pcall(function()
- for i = 1,(2 * times) do
- wait()
- coroutine.wrap(function()
- local b = p:Clone()
- b.Parent = script
- b.Position = whatpart.Position
- b.Velocity = Vector3.new(Random.new():NextNumber(min,max),Random.new():NextNumber(min,max) + 30,Random.new():NextNumber(min,max))
- table.insert(rayblacklist,b)
- b.Touched:Connect(function(what)
- if not (what:FindFirstAncestorWhichIsA("Model") and what:FindFirstAncestorWhichIsA("Model"):FindFirstChildWhichIsA("Humanoid")) and not table.find(rayblacklist,what) and what.CanCollide == true then
- local params = RaycastParams.new()
- params.FilterDescendantsInstances = {rayblacklist,whatpart:FindFirstAncestorWhichIsA("Model"):GetDescendants()}
- params.FilterType = Enum.RaycastFilterType.Blacklist
- local result = workspace:Raycast(b.Position,b.Velocity + Vector3.new(0,-3,0), params)
- if result then
- if result.Instance.Name ~= "imbloodaaaa" then
- local bloodpartfloor = Instance.new("SpawnLocation")
- bloodpartfloor.Enabled = false
- bloodpartfloor.CanCollide = false
- bloodpartfloor.Anchored = true
- bloodpartfloor.Name = "imbloodaaaa"
- bloodpartfloor.Size = Vector3.new(0.05,0.005,0.005)
- bloodpartfloor.CanCollide = false
- bloodpartfloor.Material = "Ice"
- bloodpartfloor.Transparency = 0.3
- local s = Instance.new("SpecialMesh",bloodpartfloor)
- s.MeshType = "Sphere"
- b:Destroy()
- bloodpartfloor.Position = result.Position
- local whathit = result.Instance
- local currentRightVector = whathit.CFrame.RightVector
- local upVector = result.Normal
- local newFacialVector = currentRightVector:Cross(upVector)
- bloodpartfloor.CFrame = CFrame.fromMatrix(bloodpartfloor.Position, currentRightVector, upVector, newFacialVector) * CFrame.Angles(0,0,math.rad(90))
- bloodpartfloor.Color = Color3.fromRGB(85, 0,0)
- game:GetService("Debris"):AddItem(bloodpartfloor,15)
- bloodpartfloor.Parent = workspace
- local random = Random.new():NextNumber(0.25,3)
- local tweenService = game:GetService("TweenService")
- local timeToFade = random/3
- local object = bloodpartfloor
- local tweenInfo = TweenInfo.new(timeToFade,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local goal = {}
- goal.Size = Vector3.new(random/20,random,random)
- goal.Transparency = 0.3 + random/10
- local groww = tweenService:Create(object, tweenInfo, goal)
- groww:Play()
- local tweenService = game:GetService("TweenService")
- local timeToFade = 5
- local object = bloodpartfloor
- local tweenInfo = TweenInfo.new(timeToFade,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local goal = {}
- goal.Transparency = 1
- local gone = tweenService:Create(object, tweenInfo, goal)
- delay(10,function()
- gone:Play()
- end)
- else
- local random = Random.new():NextNumber(0.25,3)/10
- local tweenService = game:GetService("TweenService")
- local timeToFade = random/3
- local object = result.Instance
- local tweenInfo = TweenInfo.new(timeToFade,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local goal = {}
- goal.Size = object.Size + Vector3.new(random/20,random,random)
- local groww = tweenService:Create(object, tweenInfo, goal)
- groww:Play()
- end
- end
- end
- end)
- end)()
- end
- end)
- end
- local pppp = Instance.new("Part",script)
- pppp.CanQuery = false
- pppp.Anchored = true
- pppp.CanCollide = false
- pppp.Size = Vector3.new()
- pppp.Transparency = 1
- local s = Instance.new("Sound")
- s.PlayOnRemove = true
- s.Volume = 1.6
- s.SoundId = "rbxassetid://6828928602"
- e = Instance.new("RemoteEvent",owner.Character)
- local hed = Instance.new("Weld",owner.Character.Torso)
- hed.Part0 = owner.Character.Head
- hed.Part1 = hed.Parent
- hed.C0 = CFrame.new(0,-0.5,0)
- hed.C1 = CFrame.new(0,1,0)
- hed.Enabled = false
- local tool = Instance.new("Tool",owner.Backpack)
- tool.RequiresHandle = false
- tool.Name = "i have an obsession with ultrakill weapons please help im begging you"
- tool.ToolTip = "i have an obsession with ultrakill weapons please help im begging you save me from this i beg i need help please help im begging you please"
- tool.TextureId = "rbxassetid://11541198228"
- tool.Grip = CFrame.Angles(math.rad(180),0,0) * CFrame.new(0,-0.5,0.5)
- local part = Instance.new("Part",tool)
- part.CanCollide = false
- part.Size = Vector3.new(0.28355,0.781,2.24625)
- local m = Instance.new("SpecialMesh",part)
- m.MeshId = "rbxassetid://10522798832"
- m.TextureId = "rbxassetid://10522947294"
- m.Scale = Vector3.new(0.065,0.065,0.065)
- local part2 = Instance.new("Part",tool)
- part2.CanCollide = false
- part2.Size = Vector3.new(0.28355,0.781,0.6134)
- local m2 = Instance.new("SpecialMesh",part2)
- m2.MeshId = "rbxassetid://10522797895"
- m2.TextureId = "rbxassetid://10522947294"
- m2.Scale = Vector3.new(0.065,0.065,0.065)
- local part3 = Instance.new("Part",tool)
- part3.CanCollide = false
- part3.Size = Vector3.new(0.6134,0.6134,0.6134)
- local m3 = Instance.new("SpecialMesh",part3)
- m3.MeshId = "rbxassetid://10522797442"
- m3.TextureId = "rbxassetid://10522947294"
- m3.Scale = Vector3.new(0.065,0.065,0.065)
- local part4 = Instance.new("Part",tool)
- part4.CanCollide = false
- part4.Size = Vector3.new(0.28355,0.781,0.6134)
- local m4 = Instance.new("SpecialMesh",part4)
- m4.MeshId = "rbxassetid://10522799754"
- m4.TextureId = "rbxassetid://10522947294"
- m4.Scale = Vector3.new(0.065,0.065,0.065)
- local weld = Instance.new("Weld",tool)
- weld.Part0 = part2
- weld.Part1 = part
- weld.C1 = CFrame.new(0,-(0.37 + 0.125),(1.09 + 0.3) - 0.05)
- local weld3 = Instance.new("Weld",tool)
- weld3.Part0 = part3
- weld3.Part1 = part
- weld3.C1 = CFrame.new(0,0.07 + 0.075,0.5 + 0.1875)
- local weld = Instance.new("Weld",owner.Character["Right Arm"])
- weld.Part0 = part
- weld.Part1 = owner.Character["Right Arm"]
- weld.C1 = CFrame.Angles(math.rad(-90),0,0) * CFrame.new(0,0.5,-2) * CFrame.Angles(math.rad(2),math.rad(2),0)
- local armw = Instance.new("Weld",owner.Character.Torso)
- armw.Part0 = owner.Character["Right Arm"]
- armw.Part1 = owner.Character.Torso
- armw.C1 = CFrame.new(1.5,0.4,0.25)
- armw.Enabled = false
- armw.C0 = CFrame.new(0,0.5,0) * CFrame.Angles(math.rad(-90),0,0)
- local tweenService = game:GetService("TweenService")
- local tweenInfo = TweenInfo.new(0.1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out)
- local goal = {}
- goal.C0 = CFrame.Angles(math.rad(-120),0,0)
- local tween = tweenService:Create(weld, tweenInfo, goal)
- local goal4 = {}
- goal4.C1 = CFrame.Angles(math.rad(-90),0,0) * CFrame.new(0,1,-2) * CFrame.Angles(math.rad(2),math.rad(2),0)
- local tween4 = tweenService:Create(weld, tweenInfo, goal4)
- local tweenInfo = TweenInfo.new(0.15,Enum.EasingStyle.Linear,Enum.EasingDirection.Out)
- local goal2 = {}
- goal2.C0 = CFrame.Angles(math.rad(-240),0,0)
- local tween2 = tweenService:Create(weld, tweenInfo, goal2)
- local goal5 = {}
- goal5.C1 = CFrame.Angles(math.rad(-90),0,0) * CFrame.new(0,1.5,-1.9) * CFrame.Angles(math.rad(2),math.rad(2),0)
- local tween5 = tweenService:Create(weld, tweenInfo, goal5)
- local tweenInfo = TweenInfo.new(0.1,Enum.EasingStyle.Quad,Enum.EasingDirection.In)
- local goal3 = {}
- goal3.C0 = CFrame.Angles(math.rad(-360),0,0)
- local tween3 = tweenService:Create(weld, tweenInfo, goal3)
- local goal6 = {}
- goal6.C1 = CFrame.Angles(math.rad(-90),0,0) * CFrame.new(0,0.5,-2) * CFrame.Angles(math.rad(2),math.rad(2),0)
- local tween6 = tweenService:Create(weld, tweenInfo, goal6)
- local tweenService = game:GetService("TweenService")
- local tweenInfo = TweenInfo.new(0.1,Enum.EasingStyle.Sine,Enum.EasingDirection.Out,0,true)
- local goal = {}
- goal.C0 = CFrame.new(0,0.5,0.2) * CFrame.Angles(math.rad(-100),0,0)
- local twee = tweenService:Create(armw, tweenInfo, goal)
- local tweenInfo = TweenInfo.new(0.15,Enum.EasingStyle.Sine,Enum.EasingDirection.Out,0,true)
- local goal = {}
- goal.C0 = CFrame.new(0,-0.1,0.2) * CFrame.Angles(math.rad(-110),0,0)
- local tweee = tweenService:Create(armw, tweenInfo, goal)
- local goal = {}
- goal.C1 = CFrame.Angles(math.rad(-90),0,0) * CFrame.new(0,0.75,-1.65) * CFrame.Angles(math.rad(14),math.rad(2),0)
- local tweeee = tweenService:Create(weld, tweenInfo, goal)
- local welll = Instance.new("Weld",owner.Character.HumanoidRootPart)
- welll.Part0 = owner.Character.Torso
- welll.Part1 = owner.Character.HumanoidRootPart
- welll.Enabled = false
- local tweenInfo = TweenInfo.new(0.1,Enum.EasingStyle.Sine,Enum.EasingDirection.Out,0,true)
- local goa = {}
- goa.C1 = welll.C1 * CFrame.Angles(math.rad(5),0,0)
- local tweee3 = tweenService:Create(welll, tweenInfo, goa)
- local equip = Instance.new("Sound")
- equip.PlayOnRemove = true
- equip.Volume = 1
- local m = Instance.new("Sound",part)
- m.Volume = 0.7
- m.SoundId = "rbxassetid://1838457617"
- m.Looped = true
- local shotcount = 24
- equip.SoundId = "rbxassetid://6870002623"
- local reload = false
- tween.Completed:Connect(function()
- tween2:Play()
- tween5:Play()
- end)
- tween2.Completed:Connect(function()
- tween3:Play()
- tween6:Play()
- end)
- tween6.Completed:Connect(function()
- wait(0.05)
- reload = false
- shotcount = 0
- end)
- tool.Equipped:Connect(function()
- equip.Parent = part
- equip.Parent = nil
- m:Play()
- end)
- tool.Equipped:Connect(function()
- owner.Character.Humanoid.WalkSpeed += 2
- reload = true
- armw.Enabled = true
- hed.Enabled = true
- tween:Play()
- tween4:Play()
- twee:Play()
- welll.Enabled = true
- end)
- tool.Unequipped:Connect(function()
- owner.Character.Humanoid.WalkSpeed -= 2
- armw.Enabled = false
- hed.Enabled = false
- welll.Enabled = false
- shotcount = 24
- m:Pause()
- end)
- thepew = false
- tool.Activated:Connect(function()
- if not reload then
- thepew = true
- end
- end)
- tool.Deactivated:Connect(function()
- thepew = false
- end)
- e.OnServerEvent:Connect(function(_,cam,c1,alpha,hitcf,sw,wcs,shift,dt)
- local lookvector = owner.Character.HumanoidRootPart.CFrame:toObjectSpace(cam).lookVector.unit
- local y = lookvector.y
- local x = 0
- hed.C0 = hed.C0:Lerp(CFrame.new(0,-0.5,0) * CFrame.Angles(-y,0,0),dt*15)
- hed.C0 = hed.C0 * CFrame.Angles(sw.y,0,0)
- if shift then
- if y > 0 then
- armw.C1 = armw.C1:Lerp(CFrame.new(1.5,0.4,0) * CFrame.Angles(y + sw.y,-(x * 0.25) + sw.x,0) * CFrame.new(0,-0.5 * (y * 0.75),-0.5 * (y * 0.75)),dt*15)
- armw.C1 = armw.C1:Lerp(armw.C1 * CFrame.new(wcs.y / 3, wcs.x / 3,0),dt*15)
- else
- armw.C1 = armw.C1:Lerp(CFrame.new(1.5,0.4,0) * CFrame.Angles((y) + sw.y,-(x * 0.25) + sw.x,0) * CFrame.new(0,0.5 * (y * 0.75),-0.5 * (y * 0.75)),dt*15)
- armw.C1 = armw.C1:Lerp(armw.C1 * CFrame.new(wcs.y / 3, wcs.x / 3,0),dt*15)
- end
- else
- if y > 0 then
- armw.C1 = armw.C1:Lerp(CFrame.new(1.5,0.4,0) * CFrame.Angles((y) + sw.y,-(x * 0.25) + sw.x,0) * CFrame.new(0,-0.5 * (y * 0.75),-0.5 * (y * 0.75)),dt*15)
- armw.C1 = armw.C1:Lerp(armw.C1 * CFrame.new(wcs.y / 3, wcs.x / 3,0),dt*15)
- else
- armw.C1 = armw.C1:Lerp(CFrame.new(1.5,0.4,0) * CFrame.Angles((y) + sw.y,-(x * 0.25) + sw.x,0) * CFrame.new(0,0.5 * (y * 0.75),-0.5 * (y * 0.75)),dt*15)
- armw.C1 = armw.C1:Lerp(armw.C1 * CFrame.new(wcs.y / 3, wcs.x / 3,0),dt*15)
- end
- end
- end)
- NLS([[
- e = script.Parent
- local tool = owner.Backpack:WaitForChild("i have an obsession with ultrakill weapons please help im begging you")
- local ITERATIONS = 8
- local SPRING = {}
- function SPRING.create(self, mass, force, damping, speed)
- local spring = {
- Target = Vector3.new();
- Position = Vector3.new();
- Velocity = Vector3.new();
- Mass = mass or 5;
- Force = force or 50;
- Damping = damping or 4;
- Speed = speed or 4;
- }
- function spring.shove(self, force)
- local x, y, z = force.X, force.Y, force.Z
- if x ~= x or x == math.huge or x == -math.huge then
- x = 0
- end
- if y ~= y or y == math.huge or y == -math.huge then
- y = 0
- end
- if z ~= z or z == math.huge or z == -math.huge then
- z = 0
- end
- self.Velocity = self.Velocity + Vector3.new(x, y, z)
- end
- function spring.update(self, dt)
- local scaledDeltaTime = math.min(dt,1) * self.Speed / ITERATIONS
- for i = 1, ITERATIONS do
- local iterationForce = self.Target - self.Position
- local acceleration = (iterationForce * self.Force) / self.Mass
- acceleration = acceleration - (self.Velocity * self.Damping)
- self.Velocity = self.Velocity + (acceleration * scaledDeltaTime)
- self.Position = self.Position + (self.Velocity * scaledDeltaTime)
- end
- return self.Position
- end
- return spring
- end
- local wc = SPRING.create()
- local sway = SPRING.create()
- local bobspeed = 1
- local bobmod = .1
- local alpha = .25
- local hitcf = CFrame.new()
- local function gb(addition, speed, modifier)
- return math.sin(tick() * addition * speed) * modifier
- end
- c1 = CFrame.new(0,0,0)
- c2 = CFrame.new(0,0,0)
- local UIS = game:GetService("UserInputService")
- shift = false
- UIS:GetPropertyChangedSignal("MouseBehavior"):Connect(function()
- if UIS.MouseBehavior == Enum.MouseBehavior.LockCenter then
- shift = true
- elseif UIS.MouseBehavior ~= Enum.MouseBehavior.LockCenter then
- shift = false
- end
- end)
- local mouse = owner:GetMouse()
- local part = Instance.new("Part",owner.Character.Head)
- part.Size = Vector3.new()
- part.CanCollide = false
- part.Transparency = 1
- local weld = Instance.new("Weld", owner.Character.Head)
- weld.Part0 = part
- weld.Part1 = owner.Character.Head
- weld.C0 = CFrame.new(0,-0.5,0.5)
- game:GetService("RunService").RenderStepped:Connect(function(dt)
- delta = game:GetService("UserInputService"):GetMouseDelta()
- local vel = owner.Character.HumanoidRootPart.Velocity
- local msway = Vector3.new(gb(10, bobspeed, bobmod), gb(5, bobspeed, bobmod), gb(5, bobspeed, bobmod))
- sway:shove(Vector3.new(delta.X / 500, delta.Y / 500))
- wc:shove((msway / 25) * dt * 60 * math.clamp(vel.Magnitude,0,30))
- local sw = sway:update(dt)
- local wcs = wc:update(dt)
- if shift == true and (owner.Character.Head.CFrame.Position - workspace.CurrentCamera.CFrame.Position).Magnitude < 1.5 then
- local x,_,z = owner.Character.HumanoidRootPart.CFrame:ToOrientation()
- local _,y,_ = workspace.CurrentCamera.CFrame:ToOrientation()
- owner.Character.HumanoidRootPart.CFrame = CFrame.new(owner.Character.HumanoidRootPart.Position) * CFrame.Angles(x,y,z)
- workspace.CurrentCamera.FieldOfView = 100
- for i,v in pairs(owner.Character:GetDescendants()) do
- if v:IsA("Part") or v:IsA("MeshPart") and v.Name ~= "Head" then
- v.LocalTransparencyModifier = 0
- end
- if v:IsA("Accessory") and (v.AccessoryType == Enum.AccessoryType.Hat or v.AccessoryType == Enum.AccessoryType.Hair or v.AccessoryType == Enum.AccessoryType.Face or v.AccessoryType == Enum.AccessoryType.Neck) and v.Handle ~= nil then
- v.Handle.Transparency = 1
- end
- end
- if owner.Character.Head.face ~= nil then
- owner.Character.Head.face.Transparency = 1
- end
- owner.Character.Head.Transparency = 1
- workspace.CurrentCamera.CameraSubject = part
- else
- workspace.CurrentCamera.FieldOfView = 70
- workspace.CurrentCamera.CameraSubject = owner.Character
- owner.Character.Head.Transparency = 0
- for i,v in pairs(owner.Character:GetDescendants()) do
- if v:FindFirstChildWhichIsA("SpecialMesh") then
- v.Transparency = 0
- end
- end
- if owner.Character.Head.face ~= nil then
- owner.Character.Head.face.Transparency = 0
- end
- end
- local laststate = owner.Character.Humanoid.AutoRotate
- if not shift and tool.Parent == owner.Character then
- if laststate ~= false then
- owner.Character.Humanoid.AutoRotate = false
- end
- owner.Character.HumanoidRootPart.CFrame = owner.Character.HumanoidRootPart.CFrame:lerp(CFrame.new(owner.Character.HumanoidRootPart.Position, Vector3.new(mouse.Hit.p.x,owner.Character.HumanoidRootPart.Position.y,mouse.Hit.p.z)),dt*15)
- e:FireServer(CFrame.new((owner.Character.HumanoidRootPart.CFrame * CFrame.new(0,1.5,0)).Position) * CFrame.Angles(CFrame.new((owner.Character.HumanoidRootPart.CFrame * CFrame.new(0,1.5,0)).Position,mouse.Hit.Position):ToEulerAnglesXYZ()) * CFrame.new(0,0,3),c1,alpha,hitcf,sw,wcs,shift,dt)
- else
- owner.Character.Humanoid.AutoRotate = true
- e:FireServer(workspace.CurrentCamera.CFrame,c1,alpha,hitcf,sw,wcs,shift,dt)
- end
- end)
- ]],e)
- coroutine.wrap(function()
- while game:GetService("RunService").Stepped:Wait() do
- if thepew and shotcount ~= 24 then
- shotcount += 1
- local muzzle = Instance.new("Part",script)
- muzzle.CanCollide = false
- muzzle.CanQuery = false
- muzzle.Anchored = true
- local c0 = weld3.C0
- coroutine.wrap(function()
- for i = 1,20 do
- weld3.C0 = weld3.C0:Lerp(c0 * CFrame.Angles(0,0,math.rad(60)),0.05)
- task.wait()
- end
- weld3.C0 = CFrame.new()
- end)()
- s.Parent = muzzle
- s.Parent = nil
- if shotcount >= 22 then
- s.PlaybackSpeed = Random.new():NextNumber(0.95,1.05) + (0.15 * (shotcount - 21))
- else
- s.PlaybackSpeed = Random.new():NextNumber(0.95,1.05)
- end
- tweee3:Play()
- muzzle.CFrame = part.CFrame * CFrame.new(0,0.25,-1.6)
- muzzle.Position = muzzle.Position + part.Velocity * owner:GetNetworkPing()
- tweee:Play()
- tweeee:Play()
- muzzle.Transparency = 1
- local attachment0 = Instance.new("Attachment")
- attachment0.Parent = muzzle
- local attachment1 = Instance.new("Attachment")
- attachment1.Parent = workspace.Terrain
- attachment1.WorldCFrame = attachment0.WorldCFrame
- local params = RaycastParams.new()
- params.FilterDescendantsInstances = {owner.Character,script}
- params.FilterType = Enum.RaycastFilterType.Blacklist
- local res = workspace:Raycast((owner.Character.HumanoidRootPart.CFrame * CFrame.new(0,1.5,0)).Position + owner.Character.Head.Velocity * owner:GetNetworkPing(),owner.Character.Head.CFrame.lookVector * 5000, params)
- local muzzle2 = Instance.new("Part",script)
- muzzle2.CanQuery = false
- muzzle2.CanCollide = false
- muzzle2.Size = Vector3.new(0.1,0.1,0.1)
- muzzle2.Anchored = true
- muzzle2.Transparency = 1
- local pe = Instance.new("ParticleEmitter",muzzle2)
- pe.Texture = "rbxassetid://13191594"
- pe.Enabled = false
- pe.Speed = NumberRange.new(5,10)
- pe.Shape = "Cylinder"
- pe.ShapeStyle = "Volume"
- pe.ShapeInOut = "Outward"
- pe.LightEmission = 0.2
- pe.LightInfluence = 0.5
- pe.Size = NumberSequence.new{NumberSequenceKeypoint.new(0, 0.125),NumberSequenceKeypoint.new(1, 0.0625)}
- pe.Lifetime = NumberRange.new(0.5, 0.75)
- pe.Rate = 500
- pe.Drag = 2
- pe.LockedToPart = true
- pe.RotSpeed = NumberRange.new(0,0)
- pe.Color = ColorSequence.new(Color3.fromRGB(242, 191, 24))
- pe.SpreadAngle = Vector2.new(-20, 20)
- pe.EmissionDirection = Enum.NormalId.Back
- pe.Acceleration = Vector3.new(0,-50,0)
- game:GetService("Debris"):AddItem(muzzle2,1)
- local beam = Instance.new("Beam")
- beam.Width0 = 0.25
- beam.Width1 = 0.2
- local p = nil
- if res then
- p = CFrame.new(res.Position)
- if res.Instance:FindFirstAncestorWhichIsA("Model") and res.Instance:FindFirstAncestorWhichIsA("Model"):FindFirstChild("Humanoid") then
- coroutine.wrap(function()
- pcall(function()
- local he = res.Instance:FindFirstAncestorWhichIsA("Model"):FindFirstChild("Humanoid").Health
- local he2 = (res.Instance:FindFirstAncestorWhichIsA("Model"):FindFirstChild("Humanoid").Health) - 15 * 2
- for h = 1, 20 do
- if (owner.Character.Head.Position - res.Instance.Position).Magnitude <= 14 then
- owner.Character.Humanoid.Health = math.clamp((owner.Character.Humanoid.Health + (he - he2)/20),0,(owner.Character.Humanoid.MaxHealth - harddamage))
- end
- wait(0.025)
- end
- end)
- end)()
- res.Instance:FindFirstAncestorWhichIsA("Model"):FindFirstChild("Humanoid").Health -= 15 * 2
- coroutine.wrap(function()
- splat(res.Instance,math.random(2,3))
- end)()
- muzzle2.CFrame = CFrame.new(res.Position) * CFrame.Angles(CFrame.new(muzzle.Position,res.Position):ToEulerAnglesXYZ()) * CFrame.Angles(0,math.rad(90),0)
- pe.Color = ColorSequence.new(Color3.fromRGB(222, 10, 7))
- else
- muzzle2.CFrame = CFrame.new(res.Position) * CFrame.Angles(CFrame.new(muzzle.Position,res.Position):ToEulerAnglesXYZ()) * CFrame.Angles(0,math.rad(90),0)
- pe.Color = ColorSequence.new(Color3.fromRGB(242, 191, 24))
- end
- else
- p = owner.Character.Head.CFrame * CFrame.new(0,0,-7000)
- muzzle2:Destroy()
- beam.Width1 = 0.125
- end
- beam.Attachment0 = attachment0
- beam.Attachment1 = attachment1
- beam.CurveSize0 = 0
- beam.CurveSize1 = 0
- beam.FaceCamera = true
- beam.LightInfluence = 0
- beam.Segments = 10
- beam.LightEmission = 1
- beam.Brightness = 0.8
- beam.Color = ColorSequence.new{ColorSequenceKeypoint.new(0, Color3.fromRGB(242, 191, 24)),ColorSequenceKeypoint.new(1, Color3.fromRGB(252, 227, 0))}
- beam.Transparency = NumberSequence.new{NumberSequenceKeypoint.new(0, 0.9),NumberSequenceKeypoint.new(1, 0.9)}
- local billboard = Instance.new("BillboardGui", muzzle)
- billboard.Size = UDim2.new(2.5,0,2.5,0)
- local frame = Instance.new("ImageLabel", billboard)
- frame.BackgroundTransparency = 1
- frame.ImageTransparency = 0
- frame.Image = "http://www.roblox.com/asset/?id=11467328624"
- frame.Size = UDim2.new(1,0,1,0)
- local gg = {}
- gg.WorldCFrame = p
- local tweenInfoo = TweenInfo.new(0.13,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local tttt = tweenService:Create(attachment1, tweenInfoo, gg)
- tttt:Play()
- coroutine.wrap(function()
- tttt.Completed:Wait()
- if pe ~= nil then
- pe:Emit(20)
- end
- end)()
- local gg = {}
- gg.Rotation = math.random(-50,50)
- gg.ImageTransparency = 1
- local tweenInfoo = TweenInfo.new(0.3,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local ttttt = tweenService:Create(frame, tweenInfoo, gg)
- ttttt:Play()
- local g = {}
- g.Width0 = 0.1
- g.Width1 = 0.1
- g.Brightness = 0.2
- local tweenInfo = TweenInfo.new(0.15,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local t = tweenService:Create(beam, tweenInfo, g)
- coroutine.wrap(function()
- for i = -1,100,1 do
- wait(0.001)
- beam.Transparency = NumberSequence.new{NumberSequenceKeypoint.new(0, (0.072 * i)),NumberSequenceKeypoint.new(1, (0.072 * i))}
- end
- end)()
- beam.Parent = muzzle
- coroutine.wrap(function()
- local gg = {}
- gg.CFrame = CFrame.new()
- local waittt = TweenInfo.new(0.3 * 1.5,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local waitt = tweenService:Create(pppp, waittt, gg)
- waitt:Play()
- waitt.Completed:Wait()
- lr = not lr
- end)()
- local gg = {}
- gg.CFrame = CFrame.new()
- local waittt = TweenInfo.new(0.15 * 1.5,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local waitt = tweenService:Create(pppp, waittt, gg)
- waitt:Play()
- waitt.Completed:Wait()
- t:Play()
- local gg = {}
- gg.CFrame = CFrame.new()
- local waittt = TweenInfo.new(0.15 * 1.5,Enum.EasingStyle.Sine,Enum.EasingDirection.Out)
- local waitt = tweenService:Create(pppp, waittt, gg)
- waitt:Play()
- waitt.Completed:Wait()
- game:GetService("Debris"):AddItem(muzzle,0.3)
- elseif thepew and shotcount == 24 and not reload then
- reload = true
- tween:Play()
- tween4:Play()
- twee:Play()
- end
- end
- end)()
Add Comment
Please, Sign In to add comment