Advertisement
ZploitKing

no

Jul 11th, 2020
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.90 KB | None | 0 0
  1. -- Hold E when you shoot to automatically aimbot and the ESP is still a work in progress --
  2. local Headshot_Key = Enum.KeyCode.E
  3. local Torsoshot_Key = Enum.KeyCode.K
  4.  
  5. local plr = game.Players.LocalPlayer
  6. local Gui = Instance.new("ScreenGui",game.CoreGui)
  7. Gui.Name = "AimbotGui"
  8. local version = "1.0.1"
  9.  
  10. HDown = false
  11. TDown = false
  12. mouse = game.Players.LocalPlayer:GetMouse()
  13. cam = game.Workspace.CurrentCamera
  14. Players = game:service("Players")
  15.  
  16. function onKeyPress(inputObject, gameProcessedEvent)
  17. if inputObject.KeyCode == Headshot_Key then
  18. if HDown == false and TDown == false then
  19. HDown = true
  20. print("[AIMBOT] Calculating closest player")
  21. local targetpoint = mouse.Hit
  22. local p = game.Players:GetChildren()
  23. local lowestdist = 99999999999
  24. local lowestplayer = nil
  25. for i=1,#p do
  26. if p[i]~=game.Players.LocalPlayer and p[i].Character~=nil and p[i].Character~=nil and p[i].TeamColor~=game.Players.LocalPlayer.TeamColor and p[i].Character.Humanoid.Health >0 and p[i].TeamColor~=BrickColor.new("White") then
  27. local dist = p[i]:DistanceFromCharacter(Vector3.new(targetpoint.X,targetpoint.Y,targetpoint.Z))
  28. if dist < lowestdist then
  29. lowestdist = dist
  30. lowestplayer = p[i]
  31. end
  32. end
  33. end
  34. if lowestplayer~=nil then
  35. print("[AIMBOT] Targeting "..lowestplayer.Name)
  36. while HDown do
  37. wait()
  38. local TPos = lowestplayer.Character.Head.Position
  39. cam.CFrame = CFrame.new(Vector3.new(cam.CFrame.X,cam.CFrame.Y,cam.CFrame.Z),Vector3.new(TPos.X,TPos.Y,TPos.Z))
  40. end
  41. end
  42. end
  43. elseif inputObject.KeyCode == Torsoshot_Key then
  44. if TDown == false and HDown == false then
  45. TDown = true
  46. print("[AIMBOT] Calculating closest player")
  47. local targetpoint = mouse.Hit
  48. local p = game.Players:GetChildren()
  49. local lowestdist = 99999999999
  50. local lowestplayer = nil
  51. for i=1,#p do
  52. if p[i]~=game.Players.LocalPlayer and p[i].Character~=nil and p[i].Character~=nil and p[i].TeamColor~=game.Players.LocalPlayer.TeamColor and p[i].Character.Humanoid.Health >0 and p[i].TeamColor~=BrickColor.new("White") then
  53. local dist = p[i]:DistanceFromCharacter(Vector3.new(targetpoint.X,targetpoint.Y,targetpoint.Z))
  54. if dist < lowestdist then
  55. lowestdist = dist
  56. lowestplayer = p[i]
  57. end
  58. end
  59. end
  60. if lowestplayer~=nil then
  61. print("[AIMBOT] Targeting "..lowestplayer.Name)
  62. while TDown do
  63. wait()
  64. local TPos = lowestplayer.Character.Torso.Position
  65. cam.CFrame = CFrame.new(Vector3.new(cam.CFrame.X,cam.CFrame.Y,cam.CFrame.Z),Vector3.new(TPos.X,TPos.Y,TPos.Z))
  66. end
  67. end
  68. end
  69. end
  70. end
  71.  
  72. function onKeyRelease(inputObject, gameProcessedEvent)
  73. if inputObject.KeyCode == Headshot_Key then
  74. HDown = false
  75. elseif inputObject.KeyCode == Torsoshot_Key then
  76. TDown = false
  77. end
  78. end
  79.  
  80. function Esp(player, username)
  81. if player ~= Players.LocalPlayer and player.Character then
  82. local torso = player.Character:FindFirstChild("Torso")
  83. if torso then
  84. local base = Instance.new("BillboardGui", workspace.CurrentCamera)
  85. local esP = Instance.new("Frame", base)
  86. base.AlwaysOnTop = true
  87. base.Enabled = true
  88. base.Size = UDim2.new(3.5,0,4.7,0)
  89. base.Name = username
  90. base.Adornee = torso
  91. base.StudsOffset = Vector3.new(0, -0.6, 0)
  92. esP.BackgroundColor3 = Color3.new(1,0,0)
  93. esP.BackgroundTransparency = 0.8
  94. esP.BorderColor3 = Color3.new(0,0,0)
  95. esP.BorderSizePixel = 1
  96. esP.Size = UDim2.new(1,0,1,0)
  97. end
  98. end
  99. end
  100.  
  101. function CheckEsp()
  102. for x,player in pairs(Players:GetChildren()) do
  103. if player then
  104. if player.TeamColor ~= plr.TeamColor then
  105. local char = player.Character
  106. if char then
  107. local torso = char:FindFirstChild("Torso")
  108. if torso then
  109. local currentcam = workspace.CurrentCamera
  110. local playerName = player.Name
  111. if currentcam:FindFirstChild(playerName) == nil then
  112. Esp(player, playerName)
  113. end
  114. end
  115. end
  116. end
  117. end
  118. end
  119. end
  120.  
  121. local function createframe(bkgc3,bkgtrans,borderc3, bordersize, name, parent, pos, rot, size, visible, zindex)
  122. local newframe = Instance.new("Frame")
  123. newframe.BackgroundColor3 = bkgc3
  124. newframe.BackgroundTransparency = bkgtrans
  125. newframe.BorderColor3 = borderc3
  126. newframe.BorderSizePixel = bordersize
  127. newframe.Name = name
  128. newframe.Parent = parent
  129. newframe.Position = pos
  130. newframe.Rotation = rot
  131. newframe.Size = size
  132. newframe.Visible = visible
  133. newframe.ZIndex = zindex
  134. return newframe
  135. end
  136.  
  137. local function createlabel(bkgc3,bkgtrans,borderc3, bordersize, name, parent, pos, rot, size, visible, zindex, font, fontsize, text, textc3, textscaled, textstrokec3, textstroketrans, texttrans, textwrapped, xalign, yalign)
  138. local newlabel = Instance.new("TextLabel")
  139. newlabel.BackgroundColor3 = bkgc3
  140. newlabel.BackgroundTransparency = bkgtrans
  141. newlabel.BorderColor3 = borderc3
  142. newlabel.BorderSizePixel = bordersize
  143. newlabel.Name = name
  144. newlabel.Parent = parent
  145. newlabel.Position = pos
  146. newlabel.Rotation = rot
  147. newlabel.Size = size
  148. newlabel.Visible = visible
  149. newlabel.ZIndex = zindex
  150. newlabel.Font = font
  151. newlabel.FontSize = fontsize
  152. newlabel.Text = text
  153. newlabel.TextColor3 = textc3
  154. newlabel.TextScaled = textscaled
  155. newlabel.TextStrokeColor3 = textstrokec3
  156. newlabel.TextStrokeTransparency = textstroketrans
  157. newlabel.TextTransparency = texttrans
  158. newlabel.TextWrapped = textwrapped
  159. newlabel.TextXAlignment = xalign
  160. newlabel.TextYAlignment = yalign
  161. return newlabel
  162. end
  163.  
  164. local function createbutton(autocolor, bkgc3,bkgtrans,borderc3, bordersize, name, parent, pos, rot, size, visible, zindex, font, fontsize, text, textc3, textscaled, textstrokec3, textstroketrans, texttrans, textwrapped, xalign, yalign)
  165. local newbutton = Instance.new("TextButton")
  166. newbutton.AutoButtonColor = autocolor
  167. newbutton.BackgroundColor3 = bkgc3
  168. newbutton.BackgroundTransparency = bkgtrans
  169. newbutton.BorderColor3 = borderc3
  170. newbutton.BorderSizePixel = bordersize
  171. newbutton.Name = name
  172. newbutton.Parent = parent
  173. newbutton.Position = pos
  174. newbutton.Rotation = rot
  175. newbutton.Size = size
  176. newbutton.Visible = visible
  177. newbutton.ZIndex = zindex
  178. newbutton.Font = font
  179. newbutton.FontSize = fontsize
  180. newbutton.Text = text
  181. newbutton.TextColor3 = textc3
  182. newbutton.TextScaled = textscaled
  183. newbutton.TextStrokeColor3 = textstrokec3
  184. newbutton.TextStrokeTransparency = textstroketrans
  185. newbutton.TextTransparency = texttrans
  186. newbutton.TextWrapped = textwrapped
  187. newbutton.TextXAlignment = xalign
  188. newbutton.TextYAlignment = yalign
  189. return newbutton
  190. end
  191.  
  192. local function createtextbox(bkgc3,bkgtrans,borderc3, bordersize, clrtext, multiline, name, parent, pos, rot, size, visible, zindex, font, fontsize, text, textc3, textscaled, textstrokec3, textstroketrans, texttrans, textwrapped, xalign, yalign)
  193. local newbox = Instance.new("TextBox")
  194. newbox.BackgroundColor3 = bkgc3
  195. newbox.BackgroundTransparency = bkgtrans
  196. newbox.BorderColor3 = borderc3
  197. newbox.BorderSizePixel = bordersize
  198. newbox.ClearTextOnFocus = clrtext
  199. newbox.MultiLine = multiline
  200. newbox.Name = name
  201. newbox.Parent = parent
  202. newbox.Position = pos
  203. newbox.Rotation = rot
  204. newbox.Size = size
  205. newbox.Visible = visible
  206. newbox.ZIndex = zindex
  207. newbox.Font = font
  208. newbox.FontSize = fontsize
  209. newbox.Text = text
  210. newbox.TextColor3 = textc3
  211. newbox.TextScaled = textscaled
  212. newbox.TextStrokeColor3 = textstrokec3
  213. newbox.TextStrokeTransparency = textstroketrans
  214. newbox.TextTransparency = texttrans
  215. newbox.TextWrapped = textwrapped
  216. newbox.TextXAlignment = xalign
  217. newbox.TextYAlignment = yalign
  218. return newbox
  219. end
  220.  
  221. local function createimagelabel(bkgc3,bkgtrans,borderc3, bordersize, name, parent, pos, rot, size, visible, zindex, image, imagetrans)
  222. local newimage = Instance.new("ImageLabel")
  223. newimage.BackgroundColor3 = bkgc3
  224. newimage.BackgroundTransparency = bkgtrans
  225. newimage.BorderColor3 = borderc3
  226. newimage.BorderSizePixel = bordersize
  227. newimage.Name = name
  228. newimage.Parent = parent
  229. newimage.Position = pos
  230. newimage.Rotation = rot
  231. newimage.Size = size
  232. newimage.Visible = visible
  233. newimage.ZIndex = zindex
  234. newimage.Image = "rbxassetid://"..image
  235. newimage.ImageTransparency = imagetrans
  236. return newimage
  237. end
  238.  
  239. -------------------------------INITIALIZE INTRO GUI-------------------------------------
  240. local IntroFrame = createframe(Color3.new(245/255,245/255,245/255),0,Color3.new(27/255,42/255,53/255),0,"IntroFrame",Gui,UDim2.new(0,-330,0,0),0,UDim2.new(0,300,1,0),true,1)
  241. --[[bar]] createframe(Color3.new(245/255,245/255,245/255),0,Color3.new(0,0,0),0,"bar",IntroFrame,UDim2.new(1,0,0,0),0,UDim2.new(0,30,0,90),true,1)
  242. --[[slant]] createimagelabel(Color3.new(1,1,1),1,Color3.new(0,0,0),0,"Slant",IntroFrame,UDim2.new(1,0,0,90),90,UDim2.new(0,30,0,30),true,1,474172996,0)
  243. --[[creator]] createlabel(Color3.new(1,1,1),1,Color3.new(0,0,0),0,"Creator",IntroFrame,UDim2.new(0,80,1,-40),0,UDim2.new(0,140,0,30),true,1,Enum.Font.Code,Enum.FontSize.Size28,"Symplicity",Color3.new(27/255,42/255,53/255), false,Color3.new(0,0,0),1,0,true,Enum.TextXAlignment.Center,Enum.TextYAlignment.Center)
  244. --[[creatorlabel]] createlabel(Color3.new(1,1,1),1,Color3.new(0,0,0),0,"CreatorLabel",IntroFrame,UDim2.new(0,80,1,-70),0,UDim2.new(0,140,0,30),true,1,Enum.Font.Code,Enum.FontSize.Size18,"Made by:",Color3.new(27/255,42/255,53/255), false,Color3.new(0,0,0),1,0,true,Enum.TextXAlignment.Center,Enum.TextYAlignment.Center)
  245. --[[desc]] createlabel(Color3.new(1,1,1),1,Color3.new(0,0,0),0,"Desc",IntroFrame,UDim2.new(0,0,0,120),0,UDim2.new(1,0,0,90),true,1,Enum.Font.SourceSansLight,Enum.FontSize.Size14,"Feel free to share, just give me creds :) The ESP was not originally created by me, I don't know who created it",Color3.new(0,0,0), true,Color3.new(0,0,0),1,0,true,Enum.TextXAlignment.Center,Enum.TextYAlignment.Center)
  246. --[[subtitle]] createlabel(Color3.new(1,1,1),1,Color3.new(0,0,0),0,"SubTitle",IntroFrame,UDim2.new(0.5,-150,0,70),0,UDim2.new(0,300,0,40),true,1,Enum.Font.SourceSansBold,Enum.FontSize.Size32,"Aimbot/ESP",Color3.new(27/255,42/255,53/255), false,Color3.new(0,0,0),1,0,true,Enum.TextXAlignment.Center,Enum.TextYAlignment.Center)
  247. --[[title]] createlabel(Color3.new(1,1,1),1,Color3.new(0,0,0),0,"Title",IntroFrame,UDim2.new(0.5,-105,0,20),0,UDim2.new(0,210,0,60),true,1,Enum.Font.SourceSansBold,Enum.FontSize.Size60,"FPS",Color3.new(27/255,42/255,53/255), false,Color3.new(0,0,0),1,0,true,Enum.TextXAlignment.Center,Enum.TextYAlignment.Center)
  248.  
  249. IntroFrame:TweenPosition(UDim2.new(0,0,0,0),Enum.EasingDirection.Out,Enum.EasingStyle.Quart,0.5,true)
  250. wait(3.5)
  251. IntroFrame:TweenPosition(UDim2.new(0,-330,0,0),Enum.EasingDirection.In,Enum.EasingStyle.Quart,0.5,true)
  252. wait(0.5)
  253. Gui:Destroy()
  254.  
  255. game:GetService("UserInputService").InputBegan:connect(onKeyPress)
  256. game:GetService("UserInputService").InputEnded:connect(onKeyRelease)
  257.  
  258. while wait(1) do
  259. CheckEsp()
  260. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement