Advertisement
robloxboblox

DH Fly Bypass

Oct 25th, 2021 (edited)
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.92 KB | None | 0 0
  1. script.Parent = game.Players.LocalPlayer.Backpack
  2. local plr = game:WaitForChild("Players").LocalPlayer
  3. local mouse = plr:GetMouse()
  4. local FlySpeed = 10
  5. localplayer = plr
  6.  
  7. function core()
  8. if workspace:FindFirstChild("Core") then
  9. workspace.Core:Destroy()
  10. end
  11.  
  12. wait()
  13. local Core = Instance.new("Part")
  14. Core.Name = "Core"
  15. Core.Size = Vector3.new(0.05, 0.05, 0.05)
  16.  
  17. spawn(function()
  18. Core.Parent = workspace
  19. local Weld = Instance.new("Weld", workspace.Core)
  20. Weld.Part0 = workspace.Core
  21. Weld.Part1 = localplayer.Character:WaitForChild("LowerTorso")
  22. Weld.C0 = CFrame.new(0, 0, 0)
  23. end)
  24. end
  25.  
  26. core()
  27.  
  28. workspace:WaitForChild("Core")
  29.  
  30. flying = true
  31.  
  32. speed=FlySpeed/5
  33. local keys={a=false,d=false,w=false,s=false}
  34. local e1
  35. local e2
  36. local function start()
  37. local pos = Instance.new("BodyPosition",workspace.Core)
  38. local gyro = Instance.new("BodyGyro",workspace.Core)
  39. pos.Name="EPIXPOS"
  40. pos.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  41. pos.position = workspace.Core.Position
  42. gyro.maxTorque = Vector3.new(9e9, 9e9, 9e9)
  43. gyro.cframe = workspace.Core.CFrame
  44. repeat
  45. wait()
  46. speed=FlySpeed/5
  47. localplayer.Character.Humanoid.PlatformStand=true
  48. local new=gyro.cframe - gyro.cframe.p + pos.position
  49. if not keys.w and not keys.s and not keys.a and not keys.d then
  50. speed=5
  51. end
  52. if keys.w then
  53. new = new + workspace.CurrentCamera.CoordinateFrame.lookVector * speed
  54. speed=speed+5
  55. end
  56. if keys.s then
  57. new = new - workspace.CurrentCamera.CoordinateFrame.lookVector * speed
  58. speed=speed+5
  59. end
  60. if keys.d then
  61. new = new * CFrame.new(speed,0,0)
  62. speed=speed+5
  63. end
  64. if keys.a then
  65. new = new * CFrame.new(-speed,0,0)
  66. speed=speed+5
  67. end
  68. pos.position=new.p
  69. if keys.w then
  70. gyro.cframe = workspace.CurrentCamera.CoordinateFrame*CFrame.Angles(-math.rad(speed*0),0,0)
  71. elseif keys.s then
  72. gyro.cframe = workspace.CurrentCamera.CoordinateFrame*CFrame.Angles(math.rad(speed*0),0,0)
  73. else
  74. gyro.cframe = workspace.CurrentCamera.CoordinateFrame
  75. end
  76. until flying == false
  77. if gyro then gyro:Destroy() end
  78. if pos then pos:Destroy() end
  79. flying=false
  80. localplayer.Character.Humanoid.PlatformStand=false
  81. speed=FlySpeed
  82. end
  83. e1=mouse.KeyDown:connect(function(key)
  84. if not workspace.Core or not workspace.Core.Parent then flying=false e1:disconnect() e2:disconnect() return end
  85. if key=="w" then
  86. keys.w=true
  87. elseif key=="s" then
  88. keys.s=true
  89. elseif key=="a" then
  90. keys.a=true
  91. elseif key=="d" then
  92. keys.d=true
  93. elseif key=="f" then
  94. if flying==true then
  95. flying=false
  96. else
  97. flying=true
  98. start()
  99. end
  100. end
  101. end)
  102. e2=mouse.KeyUp:connect(function(key)
  103. if key=="w" then
  104. keys.w=false
  105. elseif key=="s" then
  106. keys.s=false
  107. elseif key=="a" then
  108. keys.a=false
  109. elseif key=="d" then
  110. keys.d=false
  111. end
  112. end)
  113.  
  114. game.Players.LocalPlayer.CharacterAdded:Connect(function()
  115. wait()
  116. core()
  117. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement