TheUnknownDiscord

pipebom

Feb 15th, 2022 (edited)
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.72 KB | None | 0 0
  1. bom = Instance.new("Sound")
  2. bom.PlayOnRemove = true
  3. bom.SoundId = "rbxassetid://365003340"
  4. function explod(pos)
  5. coroutine.wrap(function()
  6. local pard = Instance.new("Part",script)
  7. pard.Anchored = true
  8. pard.Position = pos
  9. pard.CanCollide = false
  10. pard.Transparency = 1
  11. pard.Size = Vector3.new(0.05,0.05,0.05)
  12. bom.Parent = pard
  13. bom.TimePosition = 0.2
  14. bom.Parent = nil
  15. local pe = Instance.new("ParticleEmitter", pard)
  16. pe.Color = ColorSequence.new(Color3.fromRGB(156, 98, 6))
  17. pe.LightEmission = 0
  18. pe.LightInfluence = 1
  19. pe.EmissionDirection = "Top"
  20. pe.Orientation = Enum.ParticleOrientation.VelocityParallel
  21. pe.Size = NumberSequence.new(0.35,0)
  22. pe.Texture = "rbxassetid://243132757"
  23. pe.Transparency = NumberSequence.new(0,1)
  24. pe.Lifetime = NumberRange.new(10,14)
  25. pe.Rate = 500
  26. pe.Rotation = NumberRange.new(90)
  27. pe.RotSpeed = NumberRange.new(0)
  28. pe.Speed = NumberRange.new(70)
  29. pe.SpreadAngle = Vector2.new(-55,55)
  30. pe.Drag = NumberRange.new(1)
  31. pe.Acceleration = Vector3.new(0,-45,0)
  32. coroutine.wrap(function()
  33. wait(0.35)
  34. pe.Enabled = false
  35. end)()
  36. local billboard = Instance.new("BillboardGui", pard)
  37. billboard.Size = UDim2.new(0.125,0,0.125,0)
  38. local frame = Instance.new("ImageLabel", billboard)
  39. frame.BackgroundTransparency = 1
  40. frame.ImageTransparency = 0.25
  41. frame.Image = "http://www.roblox.com/asset/?id=5580175775"
  42. frame.Size = UDim2.new(1,0,1,0)
  43. local tweenService = game:GetService("TweenService")
  44. local timeToFade = 0.25
  45. local object = billboard
  46. local tweenInfo = TweenInfo.new(timeToFade,Enum.EasingStyle.Linear)
  47. local goal = {}
  48. goal.Size = UDim2.new(50,0,50,0)
  49. local tween = tweenService:Create(object, tweenInfo, goal)
  50. local goal2 = {}
  51. goal2.ImageTransparency = 1
  52. local tween2 = tweenService:Create(frame, tweenInfo, goal2)
  53. tween:Play()
  54. tween2:Play()
  55. game:GetService("Debris"):AddItem(billboard,0.25)
  56. game:GetService("Debris"):AddItem(pard,25)
  57. task.wait()
  58. local explosion = Instance.new("Explosion")
  59. explosion.Position = pos
  60. explosion.BlastRadius = 10
  61. explosion.Visible = false
  62. explosion.Parent = workspace
  63. explosion.Hit:Connect(function(pa)
  64. if pa.Name ~= "Base" and pa ~= pard then
  65. pa.Anchored = false
  66. end
  67. end)
  68. end)()
  69. end
  70. function pipebomb(velocity,cf,hit)
  71. coroutine.wrap(function()
  72. local p = Instance.new("Part",script)
  73. p.Position = cf
  74. p.Velocity = velocity
  75. p.Size = Vector3.new(0.418495,0.438365,1.588055)
  76. local Mesh = Instance.new("SpecialMesh")
  77. Mesh.Parent = p
  78. Mesh.MeshId = "http://www.roblox.com/asset/?id=504967762"
  79. Mesh.TextureId = "http://www.roblox.com/asset/?id=504967784"
  80. Mesh.Scale = Vector3.new(0.005,0.005,0.005)
  81. wait(0.25)
  82. p.Touched:Wait()
  83. explod(hit)
  84. p:Destroy()
  85. end)()
  86. end
  87. t = 0.5
  88. e = Instance.new("RemoteEvent",owner.PlayerGui)
  89. e.Name = "the"
  90. e.OnServerEvent:Connect(function(_,hit)
  91. local g = Vector3.new(0, -game.Workspace.Gravity, 0)
  92. local x0 = owner.Character.HumanoidRootPart.CFrame * Vector3.new(0, 2, -2)
  93. local v0 = (hit - x0 - 0.5*g*t*t)/t;
  94. pipebomb(v0,x0,hit)
  95. end)
  96. NLS([[
  97. local radius = Instance.new("Part",owner.Character)
  98. radius.Size = Vector3.new(20,20,20)
  99. radius.Material = "ForceField"
  100. radius.Anchored = true
  101. radius.CanCollide = false
  102. radius.Color = Color3.new(1,0,0)
  103. e = owner.PlayerGui:WaitForChild("the")
  104. mouse = owner:GetMouse()
  105. mouse.Button1Down:Connect(function()
  106. e:FireServer(mouse.Hit.Position)
  107. end)
  108. game:GetService("RunService").RenderStepped:Connect(function()
  109. radius.Position = mouse.Hit.Position
  110. end)
  111. ]],owner.PlayerGui)
Add Comment
Please, Sign In to add comment