Advertisement
Guest User

Phantom Forces Aimbot "X" To Activate

a guest
Apr 24th, 2019
7,053
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.00 KB | None | 0 0
  1. local api = {};
  2. local library = loadstring(game:HttpGet("https://pastebin.com/raw/j3TcLjYu", true))()
  3. local runService = game:GetService('RunService')
  4. local inputService = game:GetService('UserInputService')
  5. local ffc = game.FindFirstChild;
  6. local WorldToViewport = workspace.CurrentCamera.WorldToViewportPoint;
  7. local client = game:GetService("Players").LocalPlayer;
  8. local BLANK_VECTOR = Vector3.new();
  9. local reg = getreg or debug.getregistry;
  10. local isp = is_protected_closure or function() return false end
  11. local guv = secret953 or debug.getupvalues
  12. local islclosure = islclosure or function(f) return pcall(string.dump, f) end
  13.  
  14. for i, func in next, reg() do
  15. if type(func) == "function" and islclosure(func) and (not isp(func)) then
  16. local upv = select(2, pcall(guv, func))
  17. if type(upv) == "table" and upv.network then
  18. api.network = upv.network
  19. end
  20. end
  21. end
  22.  
  23. api.camera = guv(guv(api.network.add).funcs.killed).camera;
  24. api.hud = guv(guv(api.network.add).funcs.startvotekick).hud;
  25. api.char = guv(api.hud.fireradar).char;
  26.  
  27. local old_loadgun = api.char.loadgun;
  28. function api.char.loadgun(self, data, ...)
  29. data.camkickmin = BLANK_VECTOR;
  30. data.camkickmax = BLANK_VECTOR;
  31. data.aimcamkickmin = BLANK_VECTOR;
  32. data.aimcamkickmax = BLANK_VECTOR;
  33. data.aimtranskickmin = BLANK_VECTOR;
  34. data.aimtranskickmax = BLANK_VECTOR;
  35. data.transkickmin = BLANK_VECTOR;
  36. data.transkickmax = BLANK_VECTOR;
  37. data.rotkickmin = BLANK_VECTOR;
  38. data.rotkickmax = BLANK_VECTOR;
  39. data.aimrotkickmin = BLANK_VECTOR;
  40. data.aimrotkickmax = BLANK_VECTOR;
  41. data.hipfirespread = 0;
  42. data.hipfirestability = 0;
  43. data.swayamp = 0;
  44. data.swayspeed = 0;
  45. data.steadyspeed = 0;
  46. data.breathspeed = 0;
  47. return old_loadgun(self, data, ...)
  48. end
  49.  
  50.  
  51. local function findTarg()
  52. local _distance = math.huge
  53. local found_player = nil;
  54.  
  55. for _, player in next, game:GetService("Players"):GetPlayers() do
  56. if player ~= client and player.Team ~= client.Team and player.Character ~= nil then
  57. local vector, visible = WorldToViewport(workspace.CurrentCamera, ffc(player.Character, 'Head').CFrame.p);
  58. if ffc(player.Character, 'HumanoidRootPart') and (ffc(player.Character, 'HumanoidRootPart').Position - workspace.Lobby.Spawn1.Position).magnitude > 100 then
  59. if visible then
  60. local position_of_head = Vector2.new(vector.X, vector.Y)
  61. local center_of_screen = Vector2.new(api.camera.cframe.p.X, api.camera.cframe.p.Y)
  62. local distance_between_points = (center_of_screen - position_of_head).magnitude
  63.  
  64. local parts = workspace.CurrentCamera:GetPartsObscuringTarget({workspace.CurrentCamera.CFrame.p, ffc(player.Character, 'Head').Position}, {player.Character, workspace.Ignore, client.Character, workspace.CurrentCamera})
  65.  
  66. if (distance_between_points < _distance) and (#parts <= 0) then
  67. found_player = player;
  68. _distance = distance_between_points;
  69. end
  70. end
  71. end
  72. end
  73. end
  74.  
  75. return found_player
  76. end
  77.  
  78. local window = library:CreateWindow({underline = Color3.fromRGB(30, 30, 30), text = 'Phantom Forces', barcolor = Color3.fromRGB(234, 234, 234), bgcolor = Color3.fromRGB(80,80,80), txtcolor = Color3.fromRGB(0, 0, 0), bartextcolor = Color3.fromRGB(0, 0, 0)})
  79. window:AddToggle('Aimbot', function(a)
  80. api.aimbot = a
  81. end)
  82.  
  83. local last = tick()
  84. local targ;
  85. runService:BindToRenderStep("asd", 1, function()
  86. if tick() - last > 0.3 then
  87. targ = findTarg();
  88. last = tick();
  89. end
  90. end)
  91.  
  92. coroutine.wrap(function()
  93. while wait() do
  94. if targ and api.aimbot and inputService:IsKeyDown(Enum.KeyCode.X) then
  95. if targ.Character and ffc(targ.Character,'Head') then
  96. api.camera:setlookvector(CFrame.new(api.camera.cframe.p, ffc(targ.Character,'Head').CFrame.p).lookVector)
  97. end
  98. end
  99. end
  100. end)()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement