IHATEMICROWAVEOVEN

bad ver)

Oct 21st, 2021 (edited)
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.24 KB | None | 0 0
  1. -- SETTINGS
  2. local initialvelocity = 50
  3. local timecap = 4
  4.  
  5. -- SCRIPT
  6. function Use(...)
  7. local isthisdone = true
  8. local timecounter = 0
  9. local shouldistrafe = 0
  10. local drawme = 0
  11. local args = {...}
  12. local nearestdistance = math.huge
  13. local nearestplayer
  14. for _, i in pairs(game.Players:GetPlayers()) do
  15. local distancecheck = i:DistanceFromCharacter(args[1].Torso.Position)
  16. if distancecheck < nearestdistance then
  17. nearestplayer = i
  18. nearestdistance = distancecheck
  19. end
  20. end
  21. coroutine.wrap(function()
  22. while isthisdone == true do
  23. for i=0, 1, 0.1 do
  24. args[1].HumanoidRootPart.CFrame = args[1].HumanoidRootPart.CFrame:lerp(CFrame.lookAt(args[1].HumanoidRootPart.Position, Vector3.new(nearestplayer.Character.Torso.Position.X, args[1].HumanoidRootPart.Position.Y, nearestplayer.Character.Torso.Position.Z)), i)
  25. --args[1].HumanoidRootPart.CFrame *= CFrame.Angles(0,math.rad(1),0)
  26. wait()
  27. end
  28. end
  29. end)()
  30. local bv = Instance.new("BodyVelocity", args[1].Torso)
  31. bv.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  32. while timecap > timecounter and (args[1].Torso.Position - nearestplayer.Character.Torso.Position).Magnitude > 9 do
  33. bv.velocity = (args[1].Torso.CFrame * CFrame.Angles(0,math.rad(90*math.ceil(shouldistrafe)),0)).LookVector * initialvelocity * (1 - (timecounter / timecap))
  34. if timecounter > timecap/4 and (args[1].Torso.Position - nearestplayer.Character.Torso.Position).Magnitude < (initialvelocity * (1.25 - (timecounter / timecap))) and math.random(1,50) == 1 and shouldistrafe == 0 then
  35. timecounter -= timecap/4
  36. shouldistrafe = 1
  37. drawme = 3
  38. end
  39. timecounter += 0.1
  40. if shouldistrafe > 0.1 then
  41. shouldistrafe -= 0.1
  42. end
  43. if shouldistrafe == 0.1 then
  44. timecounter -= timecap/8
  45. shouldistrafe = 0
  46. end
  47. if drawme > 0 then
  48. if drawme % 1 == 0 then
  49. for _, i in pairs(args[1].BTorso:GetChildren()) do
  50. local i2 = i:Clone()
  51. coroutine.wrap(function()
  52. for v = 0, 1, 0.1 do
  53. i2.Transparency = v
  54. wait(0.1)
  55. end
  56. i2:Destroy()
  57. end)()
  58. end
  59. end
  60. drawme -= 0.5
  61. end
  62. wait(0.1)
  63. end
  64. isthisdone = false
  65. for i=0, 1, 0.2 do
  66. args[1].HumanoidRootPart.CFrame = args[1].HumanoidRootPart.CFrame:lerp(CFrame.lookAt(args[1].HumanoidRootPart.Position, Vector3.new(nearestplayer.Character.Torso.Position.X + nearestplayer.Character.Torso.Velocity.X, args[1].HumanoidRootPart.Position.Y, nearestplayer.Character.Torso.Position.Z + nearestplayer.Character.Torso.Velocity.Z)), i)
  67. --args[1].HumanoidRootPart.CFrame *= CFrame.Angles(0,math.rad(1),0)
  68. wait()
  69. endMarisad (bad)
  70. bv.Velocity = args[1].Torso.CFrame.LookVector
  71. wait(timecap/(2 * timecounter))
  72. bv:Destroy()
  73. local attachment = Instance.new("Attachment", args[1].Torso)
  74. attachment.CFrame = args[1].Torso.CFrame
  75. local vf = Instance.new("VectorForce", game.Workspace)
  76. vf.Attachment0 = attachment
  77. vf.ApplyAtCenterOfMass = true
  78. vf.RelativeTo = Enum.ActuatorRelativeTo.Attachment0
  79. vf.Force = Vector3.new(-100000,100000,0)
  80. wait(1)
  81. local explosion = Instance.new("Explosion", args[1].Torso)
  82. explosion.DestroyJointRadiusPercent = 0
  83. explosion.BlastPressure = 0
  84. explosion.Position = args[1].Torso.Position
  85. attachment:Destroy()
  86. vf:Destroy()
  87. end
  88.  
  89. return Use
Add Comment
Please, Sign In to add comment