Advertisement
ryanswagg20

My custom bomb Vest

Oct 2nd, 2016
156
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.14 KB | None | 0 0
  1. local Me = game:GetService("Players").LocalPlayer
  2. local Char = Me.Character
  3. local Torso = Char.Torso
  4. local TickWait = 0.6
  5. local Color = "Black"
  6. local Dead = false
  7.  
  8. pyr = (game.Players.LocalPlayer.Character)
  9.  
  10. local Tool = Instance.new("HopperBin", Me.Backpack)
  11. Tool.Name = "Bomb Vest"
  12. pyr.Humanoid.WalkSpeed = 40
  13.  
  14. local Position = Vector3.new(0,100,0)
  15. function NewPart(Parent)
  16. local Part = Instance.new("Part", Parent)
  17. Part.CanCollide = false
  18. Part.FormFactor = "Custom"
  19. Part.Position = Position
  20. Part.TopSurface = "Smooth"
  21. Part.BottomSurface = "Smooth"
  22. Part.BrickColor = BrickColor.new(Color)
  23. Position = Position + Vector3.new(0,Part.Size.Y + 10,0)
  24. return Part
  25. end
  26.  
  27. local Model = Char:FindFirstChild("Bomb")
  28. if Model then Model:Destroy() end
  29.  
  30. Model = Instance.new("Model", Char)
  31. Model.Name = "Bomb"
  32.  
  33. local Belt = NewPart(Model)
  34. Belt.Size = Vector3.new(2.2,0.5,1.2)
  35. local Weld = Instance.new("Weld", Belt)
  36. Weld.Part0 = Belt
  37. Weld.Part1 = Torso
  38. Weld.C0 = CFrame.new(0,1.1,0)
  39. local Light = Instance.new("PointLight", Belt)
  40. Light.Range = 15
  41. Light.Brightness = 5
  42. Light.Color = Color3.new(1,0,0)
  43. local Beep = Instance.new("Sound", Belt)
  44. Beep.SoundId = "http://www.roblox.com/asset/?id=300473653"
  45. local ExplodeSound = Instance.new("Sound", Belt)
  46. ExplodeSound.SoundId = "http://www.roblox.com/asset/?id=169628396"
  47. ExplodeSound.Pitch = 1
  48. ExplodeSound.Volume = 3
  49.  
  50. local Back = NewPart(Model)
  51. Back.Size = Vector3.new(1.5,1.5,0.5)
  52. local Weld = Instance.new("Weld", Back)
  53. Weld.Part0 = Back
  54. Weld.Part1 = Torso
  55. Weld.C0 = CFrame.new(0,0.1,-0.75)
  56.  
  57. local StrapLeft = NewPart(Model)
  58. StrapLeft.Size = Vector3.new(0.2,0.5,1.6)
  59. local Weld = Instance.new("Weld", StrapLeft)
  60. Weld.Part0 = StrapLeft
  61. Weld.Part1 = Torso
  62. Weld.C0 = CFrame.new(0.65,-0.9,-0.2)
  63.  
  64. local BuckleLeft = NewPart(Model)
  65. BuckleLeft.Size = Vector3.new(0.2,1.5,0.2)
  66. local Weld = Instance.new("Weld", BuckleLeft)
  67. Weld.Part0 = BuckleLeft
  68. Weld.Part1 = Torso
  69. Weld.C0 = CFrame.new(0.65,0.1,0.5)
  70.  
  71. local StrapRight = NewPart(Model)
  72. StrapRight.Size = Vector3.new(0.2,0.5,1.6)
  73. local Weld = Instance.new("Weld", StrapRight)
  74. Weld.Part0 = StrapRight
  75. Weld.Part1 = Torso
  76. Weld.C0 = CFrame.new(-0.65,-0.9,-0.2)
  77.  
  78. local BuckleRight = NewPart(Model)
  79. BuckleRight.Size = Vector3.new(0.2,1.5,0.2)
  80. local Weld = Instance.new("Weld", BuckleRight)
  81. Weld.Part0 = BuckleRight
  82. Weld.Part1 = Torso
  83. Weld.C0 = CFrame.new(-0.65,0.1,0.5)
  84.  
  85. Tool.Selected:connect(function(Mouse)
  86. TickWait = 0.3
  87. Mouse.Icon = "http://www.roblox.com/asset/?id=9109985"
  88.  
  89. Mouse.Button1Down:connect(function()
  90. if Dead == false then
  91. Dead = true
  92. wait(1)
  93. ExplodeSound:Play()
  94. local Explosion = Instance.new("Explosion", Workspace)
  95. Explosion.Position = Belt.Position
  96. Explosion.BlastPressure = 100000
  97. Explosion.DestroyJointRadiusPercent = 0.7
  98. Explosion.ExplosionType = "CratersAndDebris"
  99. Explosion.BlastRadius = 50
  100. Explosion.Hit:connect(function(Part, Distance)
  101. Part.Anchored = false
  102. if Distance <= 10 then
  103. Part:BreakJoints()
  104. end
  105. end)
  106. end
  107. end)
  108. end)
  109.  
  110. Tool.Deselected:connect(function()
  111. TickWait = 0.6
  112. end)
  113.  
  114. coroutine.wrap(function()
  115. repeat
  116. wait(TickWait)
  117. Light.Enabled = not Light.Enabled
  118. Beep:Play()
  119. until Dead == true
  120. end)()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement