Advertisement
Hex4rr

Fire Trail

Aug 21st, 2020 (edited)
188
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.85 KB | None | 0 0
  1. local value = Instance.new("NumberValue")
  2. local heightVal = Instance.new("NumberValue")
  3. heightVal.Value = -4
  4. local hval = heightVal.Value
  5. local speedVal = Instance.new("NumberValue")
  6. speedVal.Value = 30
  7. local val = value.Value
  8. local plr = game.Players.LocalPlayer;
  9. local chr = plr.Character;
  10. local hum = chr.Humanoid;
  11. local mov = {};
  12. local mov2 = {};
  13.  
  14. --[[Network]]
  15. coroutine.resume(coroutine.create(function()
  16. settings().Physics.AllowSleep = false;
  17. game.RunService.RenderStepped:Connect(function()
  18. for i, v in pairs(game.Players:GetPlayers()) do
  19. if v ~= plr then
  20. v.MaximumSimulationRadius = 0.1;
  21. v.SimulationRadius = 0;
  22. else
  23. v.MaximumSimulationRadius = math.pow(math.huge, math.huge);
  24. v.SimulationRadius = math.pow(math.huge, 2);
  25. end
  26. end
  27. end)
  28. end))
  29.  
  30. function ftp(str)
  31. local pt = {};
  32. if str ~= 'me' and str ~= 'random' then
  33. for i, v in pairs(game.Players:GetPlayers()) do
  34. if v.Name:lower():find(str:lower()) then
  35. table.insert(pt, v);
  36. end
  37. end
  38. elseif str == 'me' then
  39. table.insert(pt, plr);
  40. elseif str == 'random' then
  41. table.insert(pt, game.Players:GetPlayers()[math.random(1, #game.Players:GetPlayers())]);
  42. end
  43. return pt;
  44. end
  45.  
  46. for _, v in pairs(hum:GetAccessories()) do
  47. local b = v.Handle;
  48. b.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0);
  49. b.CanCollide = false;
  50. b:BreakJoints();
  51. for _, k in pairs(v:GetChildren()) do
  52. if not k:IsA'SpecialMesh' and not k:IsA'Part' then
  53. k:Destroy();
  54. end
  55. end
  56. local still = Instance.new('BodyAngularVelocity', b);
  57. still.MaxTorque = Vector3.new(math.huge, math.huge, math.huge);
  58. still.AngularVelocity = Vector3.new(0, 0, 0);
  59. local align = Instance.new('AlignPosition', b);
  60. align.MaxForce = 1000000;
  61. align.MaxVelocity = math.huge;
  62. align.RigidityEnabled = false;
  63. align.ApplyAtCenterOfMass = true;
  64. align.Responsiveness = 200;
  65. local a0 = Instance.new('Attachment', b);
  66. local a1 = Instance.new('Attachment', chr.Head);
  67. align.Attachment0 = a0;
  68. align.Attachment1 = a1;
  69. table.insert(mov, a1);
  70. table.insert(mov2, still);
  71. end
  72.  
  73. local par = {};
  74. for _, v in pairs(mov) do
  75. local parr = Instance.new('Part', workspace);
  76. parr.Anchored = true;
  77. parr.Size = Vector3.new(1, 1, 1);
  78. parr.Transparency = 1;
  79. parr.CanCollide = true;
  80. table.insert(par, parr);
  81. end
  82.  
  83. local rotx = 0;
  84. local rotz = math.pi / 2;
  85. local height = 0;
  86. local heighti = 1;
  87. local offset = 5;
  88. local mode = 1;
  89. local speed = speedVal.Value;
  90. local angular = Vector3.new(5, 5, 5);
  91. local l = 1;
  92. game['Run Service'].RenderStepped:Connect(function()
  93. rotx = rotx + speed / 100;
  94. rotz = rotz + speed / 100;
  95. l = (l >= 360 and 1 or l + speed);
  96.  
  97. for i, v in pairs(par) do
  98. v.CFrame = CFrame.new(chr.HumanoidRootPart.Position) * CFrame.fromEulerAnglesXYZ(0, math.rad(l + (360 / #par) * i + speed), 0) * CFrame.new(offset, 0, 0);
  99. end
  100.  
  101. if heighti == 1 then
  102. height = height + speed / 100;
  103. elseif heighti == 2 then
  104. height = height - speed / 100;
  105. end
  106. if height > 2 then
  107. heighti = 2;
  108. end
  109. if height < -1 then
  110. heighti = 1;
  111. end
  112.  
  113. if mode == 1 then
  114. for _, v in pairs(mov) do
  115. v.Position = Vector3.new(math.sin(rotx) * 3, val, math.sin(rotz) * 3);
  116. end
  117. end
  118. end)
  119. game.Players.LocalPlayer.Chatted:Connect(function(c)
  120. if c:split(' ')[1] == ';giveFire' then
  121. for _, v in pairs(mov) do
  122. chr = ftp(c:split(' ')[2])[1].Character;
  123. v.Parent = ftp(c:split(' ')[2])[1].Character.HumanoidRootPart;
  124. end
  125. end
  126. end)
  127.  
  128. local function valueChange()
  129. while true do
  130. val = -1
  131. wait(0.04)
  132. val = -1.1
  133. wait(0.02)
  134. val = -1.2
  135. wait(0.01)
  136. val = -1.3
  137. wait(0.01)
  138. val = -1.4
  139. wait(0.01)
  140. val = -1.4
  141. wait(0.01)
  142. val = -1.5
  143. wait(0.01)
  144. val = -1.6
  145. wait(0.01)
  146. val = -1.7
  147. wait(0.01)
  148. val = -1.8
  149. wait(0.01)
  150. val = -1.9
  151. wait(0.02)
  152. val = -2
  153. wait(0.02)
  154. val = -2.1
  155. wait(0.01)
  156. val = -2.2
  157. wait(0.01)
  158. val = -2.3
  159. wait(0.01)
  160. val = -2.4
  161. wait(0.01)
  162. val = -2.5
  163. wait(0.01)
  164. val = -2.6
  165. wait(0.01)
  166. val = -2.7
  167. wait(0.01)
  168. val = -2.8
  169. wait(0.02)
  170. val = -2.9
  171. wait(0.04)
  172. val = -3
  173. wait(0.04)
  174. val = -2.9
  175. wait(0.02)
  176. val = -2.8
  177. wait(0.01)
  178. val = -2.7
  179. wait(0.01)
  180. val = -2.6
  181. wait(0.01)
  182. val = -2.5
  183. wait(0.01)
  184. val = -2.4
  185. wait(0.01)
  186. val = -2.3
  187. wait(0.01)
  188. val = -2.2
  189. wait(0.02)
  190. val = -2.1
  191. wait(0.04)
  192. val = -2
  193. wait(0.04)
  194. val = -1.9
  195. wait(0.02)
  196. val = -1.8
  197. wait(0.01)
  198. val = -1.7
  199. wait(0.01)
  200. val = -1.6
  201. wait(0.01)
  202. val = -1.5
  203. wait(0.01)
  204. val = -1.4
  205. wait(0.01)
  206. val = -1.3
  207. wait(0.01)
  208. val = -1.2
  209. wait(0.02)
  210. val = -1.1
  211. wait(0.04)
  212. end
  213. end
  214. valueChange()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement