Luriyuluri

roblox script fe football

May 17th, 2024
33
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.95 KB | None | 0 0
  1. --[[
  2.  
  3. script made by MyWorld#4430
  4.  
  5. join for more cool scripts:
  6. discord.gg/pYVHtSJmEY
  7.  
  8. recommended hats:
  9. roblox.com/catalog/62234425
  10. roblox.com/catalog/63690008
  11. roblox.com/catalog/62724852
  12. roblox.com/catalog/451220849
  13. roblox.com/catalog/48474294
  14. roblox.com/catalog/48474313
  15.  
  16. note: works with any 6 hats
  17.  
  18. ]]
  19.  
  20. local netboost = Vector3.new(0, 45, 0)
  21.  
  22. local ws = game:GetService("Workspace")
  23. local rs = game:GetService("RunService")
  24. local lp = game:GetService("Players").LocalPlayer
  25.  
  26. local function align(Part0, Part1)
  27. Part0.CustomPhysicalProperties = PhysicalProperties.new(0.0001, 0.0001, 0.0001, 0.0001, 0.0001)
  28.  
  29. local att1 = Instance.new("Attachment")
  30. att1.Orientation = Vector3.new(0, 0, 0)
  31. att1.Position = Vector3.new(0, 0, 0)
  32. att1.Archivable = true
  33. local att0 = att1:Clone()
  34.  
  35. local ap = Instance.new("AlignPosition", att0)
  36. ap.ApplyAtCenterOfMass = false
  37. ap.MaxForce = math.huge
  38. ap.MaxVelocity = math.huge
  39. ap.ReactionForceEnabled = false
  40. ap.Responsiveness = 200
  41. ap.RigidityEnabled = false
  42.  
  43. local ao = Instance.new("AlignOrientation", att0)
  44. ao.MaxAngularVelocity = math.huge
  45. ao.MaxTorque = math.huge
  46. ao.PrimaryAxisOnly = false
  47. ao.ReactionTorqueEnabled = false
  48. ao.Responsiveness = 200
  49. ao.RigidityEnabled = false
  50.  
  51. ap.Attachment1 = att1
  52. ap.Attachment0 = att0
  53. ao.Attachment1 = att1
  54. ao.Attachment0 = att0
  55.  
  56. att1.Parent = Part1
  57. att0.Parent = Part0
  58.  
  59.  
  60. if netboost then
  61. spawn(function()
  62. while rs.Heartbeat:Wait() and Part0 and Part0.Parent do
  63. Part0.Velocity = netboost
  64. end
  65. end)
  66. spawn(function()
  67. while rs.Stepped:Wait() and Part0 and Part0.Parent and Part1 and Part1.Parent do
  68. Part0.Velocity = Part1.Velocity
  69. end
  70. end)
  71. end
  72. end
  73. local c = lp.Character
  74. local function gp(parent, name, className)
  75. local ret = nil
  76. if parent then
  77. for i, v in pairs(parent:GetChildren()) do
  78. if (v.Name == name) and v:IsA(className) then
  79. ret = v
  80. end
  81. end
  82. end
  83. return ret
  84. end
  85. local startpart = gp(c, "Torso", "BasePart") or gp(c, "HumanoidRootPart", "BasePart") or gp(c, "Head", "BasePart")
  86. if not startpart then
  87. print("part not found")
  88. return
  89. end
  90. local size = Vector3.new(1, 1, 2)
  91. local orient = {
  92. Vector3.new(45 ,-45, 0),
  93. Vector3.new(45, -135, 0),
  94. Vector3.new(0, 90, 0),
  95. Vector3.new(45, 45, 0),
  96. Vector3.new(45, 135, 0),
  97. Vector3.new(0, 0, 0)
  98. }
  99. local hats = {}
  100. for i, v in pairs(c:GetChildren()) do
  101. if v:IsA("Accessory") then
  102. table.insert(hats, v)
  103. end
  104. end
  105. local allhandles = {}
  106. for i, v in pairs(hats) do
  107. local handle = gp(v, "Handle", "BasePart")
  108. if handle then
  109. table.insert(allhandles, handle)
  110. end
  111. end
  112. local handles = {}
  113. for i, v in pairs(allhandles) do
  114. if v.Size == size then
  115. table.insert(handles, v)
  116. end
  117. end
  118. if #handles < #orient then
  119. for i, v in pairs(allhandles) do
  120. if not table.find(handles, v) then
  121. table.insert(handles, v)
  122. end
  123. if #handles == #orient then
  124. break
  125. end
  126. end
  127. end
  128. if #handles < #orient then
  129. print("not enough hats")
  130. return
  131. end
  132. local ball = Instance.new("Part", ws)
  133. ball.Anchored = true
  134. ball.CanCollide = false
  135. ball.CanTouch = false
  136. ball.Transparency = 1
  137. ball.Shape = "Ball"
  138. ball.Size = Vector3.new(2.3, 2.3, 2.3)
  139. ball.Position = startpart.Position
  140. for i, v in pairs(orient) do
  141. local handle = handles[i]
  142. handle:ClearAllChildren()
  143. local part = Instance.new("Part", ball)
  144. part.Massless = true
  145. part.Transparency = 1
  146. part.Anchored = true
  147. part.CanCollide = false
  148. part.Position = ball.Position
  149. part.Orientation = v
  150. local weld = Instance.new("WeldConstraint", part)
  151. weld.Part0 = ball
  152. weld.Part1 = part
  153. weld.Enabled = true
  154. handle.Parent = part
  155. align(handle, part)
  156. part.Anchored = false
  157. handle.Changed:Connect(function(prop)
  158. if (prop == "Parent") and part and part.Parent then
  159. part:Destroy()
  160. end
  161. end)
  162. end
  163. ball.CanCollide = true
  164. ball.Anchored = false
  165. c.Changed:Connect(function(prop)
  166. if (prop == "Parent") and ball and ball.Parent then
  167. ball:Destroy()
  168. end
  169. end)
Add Comment
Please, Sign In to add comment