Advertisement
ScriptingFluff

Aimbot Arsenal(NOT MY SCRIPT)

Jun 19th, 2019
605
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.89 KB | None | 0 0
  1. --[[
  2. not my script
  3. all credit to the owner of this script
  4. ]]
  5. local plrs = game:GetService("Players")
  6. local TeamBased = true ; local teambasedswitch = "o"
  7. local presskeytoaim = true; local aimkey = "e"
  8. local raycast = false
  9.  
  10. local espupdatetime = 5; autoesp = false
  11.  
  12.  
  13.  
  14. local lockaim = true; local lockangle = 5
  15.  
  16.  
  17.  
  18. --function findwat(folder, what)
  19. -- for i, smth in pairs(folder:GetChildren()) do
  20. -- if string.find(string.lower(tostring(smth)), string.lower(what)) then
  21. -- return smth
  22. -- end
  23. -- end
  24. --end
  25. --
  26. --local plrs = findwat(game, "Players")
  27.  
  28.  
  29.  
  30.  
  31. local Gui = Instance.new("ScreenGui")
  32. local Move = Instance.new("Frame")
  33. local Main = Instance.new("Frame")
  34. local EspStatus = Instance.new("TextLabel")
  35. local st1 = Instance.new("TextLabel")
  36. local st1_2 = Instance.new("TextLabel")
  37. local st1_3 = Instance.new("TextLabel")
  38. local Name = Instance.new("TextLabel")
  39. --Properties:
  40. Gui.Name = "Gui"
  41. Gui.Parent = plrs.LocalPlayer:WaitForChild("PlayerGui")
  42.  
  43. Move.Name = "Move"
  44. Move.Parent = Gui
  45. Move.BackgroundColor3 = Color3.new(0.545098, 0, 0)
  46. Move.BackgroundTransparency = 1
  47. Move.BorderSizePixel = 0
  48. Move.Draggable = true
  49. Move.Position = UDim2.new(0.005, 0, -0.15, 0)
  50. Move.Size = UDim2.new(0.28141585, 0, 0.0320388414, 0)
  51.  
  52. Main.Name = "Main"
  53. Main.Parent = Move
  54. Main.BackgroundColor3 = Color3.new(1, 1, 1)
  55. Main.Position = UDim2.new(0, -7, 20.9960003, 0)
  56. Main.Size = UDim2.new(1, 0, 5.79699993, 0)
  57. Main.Style = Enum.FrameStyle.RobloxSquare
  58.  
  59. EspStatus.Name = "EspStatus"
  60. EspStatus.Parent = Main
  61. EspStatus.BackgroundColor3 = Color3.new(1, 1, 1)
  62. EspStatus.BackgroundTransparency = 1
  63. EspStatus.Position = UDim2.new(0, 0, 0.300000012, 0)
  64. EspStatus.Size = UDim2.new(1, 0, 0.162, 0)
  65. EspStatus.Font = Enum.Font.ArialBold
  66. EspStatus.Text = "Press O to change team based mode"
  67. EspStatus.TextColor3 = Color3.new(0.6, 0.196078, 0.8)
  68. EspStatus.TextScaled = true
  69. EspStatus.TextWrapped = true
  70.  
  71. st1.Name = "st1"
  72. st1.Parent = Main
  73. st1.BackgroundColor3 = Color3.new(1, 1, 1)
  74. st1.BackgroundTransparency = 1
  75. st1.Position = UDim2.new(0.271787882, 0, 0, 0)
  76. st1.Size = UDim2.new(0.728211343, 0, 0.161862016, 0)
  77. st1.Font = Enum.Font.ArialBold
  78. st1.Text = ""
  79. st1.TextColor3 = Color3.new(0.0784314, 0.541176, 0)
  80. st1.TextScaled = true
  81. st1.TextSize = 14
  82. st1.TextWrapped = true
  83.  
  84. st1_2.Name = "st1"
  85. st1_2.Parent = Main
  86. st1_2.BackgroundColor3 = Color3.new(1, 1, 1)
  87. st1_2.BackgroundTransparency = 1
  88. st1_2.Position = UDim2.new(0, 0, 0.875999987, 0)
  89. st1_2.Size = UDim2.new(0.999999881, 0, 0.161862016, 0)
  90. st1_2.Font = Enum.Font.ArialBold
  91. st1_2.Text = "Press E to lock on a person inside ur view"
  92. st1_2.TextColor3 = Color3.new(0.6, 0.196078, 0.8)
  93. st1_2.TextScaled = true
  94. st1_2.TextWrapped = true
  95.  
  96. st1_3.Name = "st1"
  97. st1_3.Parent = Main
  98. st1_3.BackgroundColor3 = Color3.new(1, 1, 1)
  99. st1_3.BackgroundTransparency = 1
  100. st1_3.Position = UDim2.new(0, 0, 0.54, 0)
  101. st1_3.Size = UDim2.new(1, 0, 0.261999995, 0)
  102. st1_3.Font = Enum.Font.ArialBold
  103. st1_3.Text = "Press L to enable esp loop and press T to update esp"
  104. st1_3.TextColor3 = Color3.new(0.6, 0.196078, 0.8)
  105. st1_3.TextScaled = true
  106. st1_3.TextWrapped = true
  107.  
  108.  
  109. Name.Name = "Name"
  110. Name.Parent = Move
  111. Name.BackgroundColor3 = Color3.new(0.545098, 0, 0)
  112. Name.BackgroundTransparency = 1
  113. Name.Position = UDim2.new(0, 25, 20.9860001, 0)
  114. Name.Size = UDim2.new(0.838, 0, 1.27999997, 0)
  115. Name.Font = Enum.Font.Arcade
  116. Name.Text = "ARSENAL GUI"
  117. Name.TextColor3 = Color3.new(0.541176, 0.168627, 0.886275)
  118. Name.TextScaled = true
  119. Name.TextSize = 12
  120. Name.TextWrapped = true
  121. -- Scripts:
  122.  
  123.  
  124. local plrsforaim = {}
  125.  
  126. local lplr = game:GetService("Players").LocalPlayer
  127. Move.Draggable = true
  128. Gui.ResetOnSpawn = false
  129. Gui.Name = "Chat"
  130. Gui.DisplayOrder = 999
  131.  
  132. Gui.Parent = plrs.LocalPlayer.PlayerGui
  133.  
  134.  
  135. f = {}
  136. local espforlder
  137.  
  138. f.addesp = function()
  139. --print("ESP ran")
  140. if espforlder then
  141. else
  142. espforlder = Instance.new("Folder")
  143. espforlder.Parent = game.Workspace.CurrentCamera
  144. end
  145. for i, v in pairs(espforlder:GetChildren()) do
  146. v:Destroy()
  147. end
  148. for _, plr in pairs(plrs:GetChildren()) do
  149. if plr.Character and plr.Character.Humanoid.Health > 0 and plr.Name ~= lplr.Name then
  150. if TeamBased == true then
  151. if plr.Team.Name ~= plrs.LocalPlayer.Team.Name then
  152. local e = espforlder:FindFirstChild(plr.Name)
  153. if not e then
  154. --print("Added esp for team based")
  155. local bill = Instance.new("BillboardGui", espforlder)
  156. bill.Name = plr.Name
  157. bill.AlwaysOnTop = true
  158. bill.Size = UDim2.new(1,0,1,0)
  159. bill.Adornee = plr.Character.Head
  160. local Frame = Instance.new('Frame',bill)
  161. Frame.Active = true
  162. Frame.BackgroundColor3 = Color3.new(0.862745, 0.0784314, 0.235294)
  163. Frame.BackgroundTransparency = 0
  164. Frame.BorderSizePixel = 0
  165. Frame.AnchorPoint = Vector2.new(.5, .5)
  166. Frame.Position = UDim2.new (0.5,0,0.5,0)
  167. Frame.Size = UDim2.new (1,0,1,0)
  168. Frame.Rotation = 0
  169. plr.Character.Humanoid.Died:Connect(function()
  170. bill:Destroy()
  171. end)
  172. end
  173. end
  174. else
  175. local e = espforlder:FindFirstChild(plr.Name)
  176. if not e then
  177. --print("Added esp")
  178. local bill = Instance.new("BillboardGui", espforlder)
  179. bill.Name = plr.Name
  180. bill.AlwaysOnTop = true
  181. bill.Size = UDim2.new(1,0,1,0)
  182. bill.Adornee = plr.Character.Head
  183. local Frame = Instance.new('Frame',bill)
  184. Frame.Active = true
  185. Frame.BackgroundColor3 = Color3.new(0/255,255/255,0/255)
  186. Frame.BackgroundTransparency = 0
  187. Frame.BorderSizePixel = 0
  188. Frame.AnchorPoint = Vector2.new(.5, .5)
  189. Frame.Position = UDim2.new (0.5,0,0.5,0)
  190. Frame.Size = UDim2.new (1,0,1,0)
  191. Frame.Rotation = 0
  192. plr.Character.Humanoid.Died:Connect(function()
  193. bill:Destroy()
  194. end)
  195. end
  196. end
  197.  
  198.  
  199. end
  200. end
  201. end
  202. local cam = game.Workspace.CurrentCamera
  203.  
  204. local mouse = lplr:GetMouse()
  205. local switch = false
  206. local key = "k"
  207. local aimatpart = nil
  208. mouse.KeyDown:Connect(function(a)
  209. if a == "t" then
  210. print("worked1")
  211. f.addesp()
  212. elseif a == "u" then
  213. if raycast == true then
  214. raycast = false
  215. else
  216. raycast = true
  217. end
  218. elseif a == "l" then
  219. if autoesp == false then
  220. autoesp = true
  221. else
  222. autoesp = false
  223. end
  224. end
  225. if a == "j" then
  226. if mouse.Target then
  227. mouse.Target:Destroy()
  228. end
  229. end
  230. if a == key then
  231. if switch == false then
  232. switch = true
  233. else
  234. switch = false
  235. if aimatpart ~= nil then
  236. aimatpart = nil
  237. end
  238. end
  239. elseif a == teambasedswitch then
  240. if TeamBased == true then
  241. TeamBased = false
  242. teambasedstatus.Text = tostring(TeamBased)
  243. else
  244. TeamBased = true
  245. teambasedstatus.Text = tostring(TeamBased)
  246. end
  247. elseif a == aimkey then
  248. if not aimatpart then
  249. local maxangle = math.rad(20)
  250. for i, plr in pairs(plrs:GetChildren()) do
  251. if plr.Name ~= lplr.Name and plr.Character and plr.Character.Head and plr.Character.Humanoid and plr.Character.Humanoid.Health > 1 then
  252. if TeamBased == true then
  253. if plr.Team.Name ~= lplr.Team.Name then
  254. local an = checkfov(plr.Character.Head)
  255. if an < maxangle then
  256. maxangle = an
  257. aimatpart = plr.Character.Head
  258. end
  259. end
  260. else
  261. local an = checkfov(plr.Character.Head)
  262. if an < maxangle then
  263. maxangle = an
  264. aimatpart = plr.Character.Head
  265. end
  266. print(plr)
  267. end
  268. plr.Character.Humanoid.Died:Connect(function()
  269. if aimatpart.Parent == plr.Character or aimatpart == nil then
  270. aimatpart = nil
  271. end
  272. end)
  273. end
  274. end
  275. else
  276. aimatpart = nil
  277. end
  278. end
  279. end)
  280.  
  281. function getfovxyz (p0, p1, deg)
  282. local x1, y1, z1 = p0:ToOrientation()
  283. local cf = CFrame.new(p0.p, p1.p)
  284. local x2, y2, z2 = cf:ToOrientation()
  285. --local d = math.deg
  286. if deg then
  287. --return Vector3.new(d(x1-x2), d(y1-y2), d(z1-z2))
  288. else
  289. return Vector3.new((x1-x2), (y1-y2), (z1-z2))
  290. end
  291. end
  292.  
  293. function getaimbotplrs()
  294. plrsforaim = {}
  295. for i, plr in pairs(plrs:GetChildren()) do
  296. if plr.Character and plr.Character.Humanoid and plr.Character.Humanoid.Health > 0 and plr.Name ~= lplr.Name and plr.Character.Head then
  297.  
  298. if TeamBased == true then
  299. if plr.Team.Name ~= lplr.Team.Name then
  300. local cf = CFrame.new(game.Workspace.CurrentCamera.CFrame.p, plr.Character.Head.CFrame.p)
  301. local r = Ray.new(cf, cf.LookVector * 10000)
  302. local ign = {}
  303. for i, v in pairs(plrs.LocalPlayer.Character:GetChildren()) do
  304. if v:IsA("BasePart") then
  305. table.insert(ign , v)
  306. end
  307. end
  308. local obj = game.Workspace:FindPartOnRayWithIgnoreList(r, ign)
  309. if obj.Parent == plr.Character and obj.Parent ~= lplr.Character then
  310. table.insert(plrsforaim, obj)
  311. end
  312. end
  313. else
  314. local cf = CFrame.new(game.Workspace.CurrentCamera.CFrame.p, plr.Character.Head.CFrame.p)
  315. local r = Ray.new(cf, cf.LookVector * 10000)
  316. local ign = {}
  317. for i, v in pairs(plrs.LocalPlayer.Character:GetChildren()) do
  318. if v:IsA("BasePart") then
  319. table.insert(ign , v)
  320. end
  321. end
  322. local obj = game.Workspace:FindPartOnRayWithIgnoreList(r, ign)
  323. if obj.Parent == plr.Character and obj.Parent ~= lplr.Character then
  324. table.insert(plrsforaim, obj)
  325. end
  326. end
  327.  
  328.  
  329. end
  330. end
  331. end
  332.  
  333. function aimat(part)
  334. cam.CFrame = CFrame.new(cam.CFrame.p, part.CFrame.p)
  335. end
  336. function checkfov (part)
  337. local fov = getfovxyz(game.Workspace.CurrentCamera.CFrame, part.CFrame)
  338. local angle = math.abs(fov.X) + math.abs(fov.Y)
  339. return angle
  340. end
  341.  
  342. game:GetService("RunService").RenderStepped:Connect(function()
  343. if aimatpart then
  344. aimat(aimatpart)
  345. if aimatpart.Parent == plrs.LocalPlayer.Character then
  346. aimatpart = nil
  347. end
  348. end
  349.  
  350.  
  351. -- if switch == true then
  352. -- local maxangle = 99999
  353. --
  354. -- --print("Loop")
  355. -- if true and raycast == false then
  356. -- for i, plr in pairs(plrs:GetChildren()) do
  357. -- if plr.Name ~= lplr.Name and plr.Character and plr.Character.Head and plr.Character.Humanoid and plr.Character.Humanoid.Health > 1 then
  358. -- if TeamBased then
  359. -- if plr.Team.Name ~= lplr.Team.Name or plr.Team.TeamColor ~= lplr.Team.TeamColor then
  360. -- local an = checkfov(plr.Character.Head)
  361. -- if an < maxangle then
  362. -- maxangle = an
  363. -- aimatpart = plr.Character.Head
  364. -- if an < lockangle then
  365. -- break
  366. -- end
  367. -- end
  368. -- end
  369. -- else
  370. -- local an = checkfov(plr.Character.Head)
  371. -- if an < maxangle then
  372. -- maxangle = an
  373. -- aimatpart = plr.Character.Head
  374. -- if an < lockangle then
  375. -- break
  376. -- end
  377. -- end
  378. -- end
  379. --
  380. --
  381. --
  382. --
  383. -- end
  384. -- end
  385. -- elseif raycast == true then
  386. --
  387. -- end
  388.  
  389. if raycast == true and switch == false and not aimatpart then
  390. getaimbotplrs()
  391. aimatpart = nil
  392. local maxangle = 999
  393. for i, v in ipairs(plrsforaim) do
  394. if v.Parent ~= lplr.Character then
  395. local an = checkfov(v)
  396. if an < maxangle and v ~= lplr.Character.Head then
  397. maxangle = an
  398. aimatpart = v
  399. print(v:GetFullName())
  400. v.Parent.Humanoid.Died:connect(function()
  401. aimatpart = nil
  402. end)
  403. end
  404. end
  405. end
  406.  
  407. end
  408. end)
  409. delay(0, function()
  410. while wait(espupdatetime) do
  411. if autoesp == true then
  412. pcall(function()
  413. f.addesp()
  414. end)
  415. end
  416. end
  417. end)
  418. warn("loaded")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement