Advertisement
Josemmoya

Untitled

Jan 15th, 2020
230
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.96 KB | None | 0 0
  1. script.Parent = game.Workspace.Josemmoya.Head
  2.  
  3. local hat = script.Parent
  4. local Rocket = hat
  5. local block = hat:clone()
  6. block.Size = Vector3.new(4,7,3)
  7. block.Name = "shield"
  8. number = 4
  9. radius = 6
  10.  
  11. teapot = hat:clone()
  12. teapot.Size = Vector3.new(65,65,65)
  13. teapot.Mesh.Scale = Vector3.new(100,100,100)
  14. teapot.Name = "massive teapot"
  15. teapot.Size = Vector3.new(65,65,65)
  16. teapot.Mesh.Scale = Vector3.new(100,100,100)
  17. teapot.Name = "massive teapot"
  18.  
  19. function either(number)
  20. if(math.random(1,2) == 1) then return number end
  21. return -number
  22. end
  23.  
  24. function glue(x, y)
  25. weld = Instance.new("Weld")
  26.  
  27. weld.Part0 = x
  28. weld.Part1 = y
  29.  
  30. local HitPos = x.Position
  31.  
  32. local CJ = CFrame.new(HitPos)
  33. local C0 = x.CFrame:inverse() *CJ
  34. local C1 = y.CFrame:inverse() * CJ
  35.  
  36. weld.C0 = C0
  37. weld.C1 = C1
  38.  
  39. weld.Parent = x
  40. end
  41.  
  42. function fire(vTarget,offset)
  43. obj = vTarget
  44. vTarget = vTarget.Position
  45.  
  46.  
  47. local dir = vTarget - hat.Position
  48. dir = dir.unit
  49. missile = {}
  50. pos = {}
  51. hatFrame = {}
  52. misFrame = {}
  53. seed = {}
  54. for i=1,number do
  55. seed[i] = math.random(0,100000)
  56. missile[i] = Rocket:clone()
  57. missile[i].Name = "teapot" .. seed[i]
  58. pos[i] = hat.Position + Vector3.new(math.random(-10,10),4,math.random(-10,10))
  59. hatFrame[i] = hat.CFrame
  60. misFrame[i] = hatFrame[i] * CFrame.new(math.random(-10,10),math.random(-10,10),math.random(-10,0))
  61. --missile.Position = pos
  62. missile[i].CFrame = CFrame.new(pos[i], pos[i] + dir)
  63.  
  64. missile[i].RocketScript.Disabled = false
  65. missile[i].Parent = game.Workspace
  66. missile[i].homing:Fire()
  67. missile[i].homing.ThrustP = 50
  68. missile[i].homing.TargetOffset = misFrame[i].p + offset
  69. end
  70.  
  71. wait(.4)
  72.  
  73. for i=1,number do
  74. teapot = game.Workspace:findFirstChild("teapot" .. seed[i])
  75. if(teapot ~= nil) then
  76. teapot.homing.ThrustP = 30
  77. teapot.homing.TargetOffset = Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2))
  78. teapot.homing.Target = obj
  79. end
  80. end
  81. end
  82.  
  83. function shield()
  84. Torso = hat.Parent.Torso.CFrame
  85. bricks = {}
  86. bricks[1] = Torso * CFrame.new(0,0,-radius)
  87. bricks[2] = Torso * CFrame.new(0,0,radius)
  88. bricks[3] = Torso * CFrame.new(-radius,0,0)
  89. bricks[4] = Torso * CFrame.new(radius,0,0)
  90. for i=1,#bricks do
  91. newbrick = block:clone()
  92. newbrick.CFrame = CFrame.new(bricks[i].p, Torso.p)
  93. newbrick.Parent = game.Workspace
  94. glue(newbrick,hat.Parent.Torso)
  95. end
  96. end
  97.  
  98. debounce = true
  99. function teapottouch(hit)
  100. if not debounce then return end
  101. debounce = false
  102. pos = hit.Position
  103. boom = Instance.new("Explosion")
  104. boom.BlastRadius = 30
  105. boom.BlastPressure = 500000
  106. boom.Position = pos
  107. boom.Parent = game.Workspace
  108. wait(1)
  109. debounce = true
  110. end
  111.  
  112. function gf(player)
  113. Torso = player.Position
  114. pos = Torso + Vector3.new(0,750,0)
  115. pot = teapot:clone()
  116. pot.Position = pos
  117. pot.Elasticity = 0.1
  118. pot.Parent = game.Workspace
  119. connection = pot.Touched:connect(teapottouch)
  120. end
  121.  
  122. function kill(hit)
  123. local human = hit.Parent:findFirstChild("Humanoid")
  124. if (human ~= nil) then
  125. human.Health = 0
  126. end
  127. end
  128.  
  129. function trigger(msg, recipient)
  130. if(msg == "spew!") then
  131. children = game.Players:children()
  132. for i=1,#children do
  133. if(children[i].Name ~= "[YOUR NAME]") then fire(children[i].Character.Torso,Vector3.new(0,25,0)) end
  134. end
  135. end
  136. if(msg == "abort") then
  137. children = game.Workspace:children()
  138. for i=1,#children do
  139. if(string.sub(children[i].Name,1,6) == "teapot") then children[i].homing:Abort() end
  140. if(children[i].Name == "shield" or children[i].Name == "massive teapot" or children[i].Name == "TVehicle") then children[i]:remove() end
  141. end
  142. end
  143. if(msg == "shield!") then
  144. shield()
  145. end
  146. if(msg == "i can fly") then
  147. hat.TVehicle:move((hat.CFrame * CFrame.new(0,3,-10)).p)
  148. hat.TVehicle.Front.Propulsion.TargetOffset = hat.Position + Vector3.new(5,-5,0)
  149. end
  150. if(msg == "arm front") then
  151. hat.TVehicle.Front.Touched:connect(kill)
  152. end
  153. if(tonumber(msg) ~= nil) then
  154. power = tonumber(msg)
  155. hat.TVehicle.Front.Propulsion.MaxSpeed = power
  156. end
  157. children = game.Players:children()
  158. for i=1,#children do
  159. if(children[i].Name == msg) then
  160. torso = children[i].Character.Torso
  161. prop = hat.TVehicle.Front.Propulsion:clone()
  162. prop.Target = hat.TVehicle.back
  163. prop.MaxSpeed = 1000
  164. prop.TargetOffset = Vector3.new(0,0,0)
  165. prop.MaxTorque = Vector3.new(4e+10,4e+10,4e+10)
  166. prop.Parent = torso
  167. prop:Fire()
  168. end
  169. end
  170. if(string.sub(msg,1,6) ~= "Teapot") then return end
  171. name = string.sub(msg,8,-2)
  172. children = game.Players:children()
  173. for i=1,#children do
  174. if(children[i].Name == name) then fire(children[i].Character.Torso,Vector3.new(0,25,0)) end
  175. end
  176.  
  177. end
  178.  
  179. wait(1)
  180. while hat.Parent.Name == "Workspace" do wait(2) end
  181. print("Hat picked up")
  182. name = hat.Parent.Name
  183. if(name ~= "BP610" and name ~= "lawhl") then return end
  184. print("vinceyoung66 confirmed")
  185. game.Players.ic3w0lf589.Chatted:connect(trigger)
  186.  
  187. hat.Fly2.Parent = game.Players.ic3w0lf589.Backpack
  188. hat["The One Tool"].Parent = game.Players.BP610.Backpack
  189.  
  190. --~Vinceyoung66~
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement