Advertisement
Guest User

Untitled

a guest
Jul 16th, 2018
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 20.50 KB | None | 0 0
  1. --Sh1t Hax Version 0.1Alpha
  2. surface.CreateFont("ESP_Font_Main",{font = "coolvetica", size = 20})
  3. surface.CreateFont("ESP_Font_lol", {font = "coolvetica", size = 15})
  4. local Shithacks = {}
  5. Shithacks.Aimbot = {}
  6. Shithacks.Options = {}
  7. Shithacks.Movement = {}
  8. Shithacks.Visuals = {}
  9.  
  10. Shithacks.Options["AimbotFOV"] = 180
  11. Shithacks.Options["AimbotBind"] = 32
  12. Shithacks.Options["ToggleAimbot"] = true
  13. Shithacks.Options["WallAim"] = false
  14. Shithacks.Options["NextTarget"] = true
  15. Shithacks.Options["LockTargetToggle"] = true
  16. Shithacks.Options["Bhop"] = false
  17. Shithacks.Options["TargetPrioritization"] = 1
  18. Shithacks.Options["AutoShoot"] = false
  19. Shithacks.Options["ESP_Health"] = false
  20. Shithacks.Options["ESP_Names"] = false
  21. Shithacks.Options["ESP_Boxes"] = false
  22. Shithacks.Options["ESP_Boxes_3d"] = true
  23. Shithacks.Options["Snaplines"] = false
  24. Shithacks.Options["Snaplines_Names"] = false
  25. Shithacks.Options["Smooth"] = 5
  26. Shithacks.Options["Smooth2"] = 0
  27. Shithacks.Aimbot["Target"] = nil
  28. Shithacks.Aimbot["NextTargetDead"] = true
  29. Shithacks.Aimbot["ClosestEnemy"] = math.huge
  30. Shithacks.Movement["OnGround"] = nil
  31. Shithacks.Visuals["SnapTarget"] = nil
  32. Shithacks.Options["Boxes_Value"] = true
  33.  
  34. local FindMetaTable = FindMetaTable
  35. local cm = FindMetaTable"CUserCmd"
  36. local vm = FindMetaTable"Vector"
  37. local ply = LocalPlayer()
  38. local oldRC = render.Capture
  39. local rndrView = render.RenderView
  40.  
  41. concommand.Add("shit_menu", function()
  42. menu()
  43. end)
  44. concommand.Add("Unload_Shitmenu", function(ply, cmd, args)
  45. hook.Remove("CreateMove", "Test23")
  46. hook.Remove("Think", "Test12")
  47. hook.Remove("HUDPaint", "Test34")
  48. concommand.Remove("Unload_Shitmenu")
  49. concommand.Remove("shit_menu")
  50. print ("shit hacks unloaded.")
  51. timer.Simple(1, function() print(" ") print(" ") print(" ") print(" ") print(" ") print(" ")end)
  52. end)
  53. function menu(Tab)
  54. local shitmenu = vgui.Create( "DFrame" )
  55. shitmenu:SetSize(ScrW() / 1.75, ScrH() / 1.5)
  56. shitmenu:SetTitle("Shit hack")
  57. shitmenu:SetVisible(true)
  58. shitmenu:SetDraggable(false)
  59. shitmenu:ShowCloseButton(true)
  60. shitmenu:MakePopup()
  61. shitmenu:Center()
  62. function shitmenu:Paint(w, h)
  63. draw.RoundedBox( 0, 0, 0, w, h / 20, Color(0,0,0,255) )
  64. draw.RoundedBox( 0, 0, 0, w, h, Color(0,10,20,150) )
  65. end
  66.  
  67. local Aimbot = vgui.Create("DPanel", shitmenu)
  68. Aimbot:SetPos(0 , (ScrH() / 10))
  69. Aimbot:SetSize(shitmenu:GetWide(), (shitmenu:GetTall() - shitmenu:GetTall() / 10 - shitmenu:GetTall() / 20))
  70. Aimbot:SetBackgroundColor(Color(255, 0, 255, 50))
  71. Aimbot:SetVisible(false)
  72.  
  73. local Bhop = vgui.Create("DPanel", shitmenu)
  74. Bhop:SetPos(0 , (ScrH() / 10))
  75. Bhop:SetSize(shitmenu:GetWide(), (shitmenu:GetTall() - shitmenu:GetTall() / 10 - shitmenu:GetTall() / 20))
  76. Bhop:SetBackgroundColor(Color(255, 0, 255, 50))
  77. Bhop:SetVisible(false)
  78.  
  79. local Visuals = vgui.Create("DPanel", shitmenu)
  80. Visuals:SetPos(0, (ScrH() / 10))
  81. Visuals:SetSize(shitmenu:GetWide(), (shitmenu:GetTall() - shitmenu:GetTall() / 10 - shitmenu:GetTall() / 20))
  82. Visuals:SetBackgroundColor(Color(255, 0, 255, 50))
  83. Visuals:SetVisible(false)
  84.  
  85. function ChangeTab (Tab)
  86. Aimbot:SetVisible(false)
  87. Bhop:SetVisible(false)
  88. Visuals:SetVisible(false)
  89. Tab:SetVisible(true)
  90. end
  91.  
  92. function MoveShit(Var)
  93. if Var == "ToggleAimbot" or Var == "ESP_Health" or Var == "Bhop" then
  94. return 0
  95. elseif Var == "WallAim" then
  96. if Shithacks.Options["ToggleAimbot"] then
  97. return 3
  98. else
  99. return ScrH()
  100. end
  101. elseif Var == "NextTarget" then
  102. if Shithacks.Options["ToggleAimbot"] then
  103. return 2
  104. else
  105. return ScrH()
  106. end
  107. elseif Var == "LockTargetToggle" then
  108. if Shithacks.Options["ToggleAimbot"] then
  109. return 1
  110. else
  111. return ScrH()
  112. end
  113. elseif Var == "AutoShoot" then
  114. if Shithacks.Options["ToggleAimbot"] then
  115. return 4
  116. else
  117. return ScrH()
  118. end
  119. elseif Var == "AimbotFOV" then
  120. if Shithacks.Options["ToggleAimbot"] then
  121. return 3
  122. else
  123. return ScrH()
  124. end
  125. elseif Var == "AimbotBind" then
  126. if Shithacks.Options["ToggleAimbot"] then
  127. return 0
  128. else
  129. return ScrH()
  130. end
  131. elseif Var == "TargetPrioritization" then
  132. if Shithacks.Options["ToggleAimbot"] then
  133. return 2.5
  134. else
  135. return ScrH()
  136. end
  137. elseif Var == "ESP_Names" then
  138. return 1
  139. elseif Var == "Snaplines" then
  140. return 2
  141. elseif Var == "Snaplines_Names" then
  142. if Shithacks.Options["Snaplines"] then
  143. return 3
  144. else
  145. return ScrH()
  146. end
  147. elseif Var == "ESP_Boxes" then
  148. if Shithacks.Options["Snaplines"] then
  149. return 4
  150. else
  151. return 3
  152. end
  153. elseif Var == "ESP_Boxes_3d" then
  154. if Shithacks.Options["Snaplines"] && Shithacks.Options["ESP_Boxes"] then
  155. return 5
  156. elseif Shithacks.Options["ESP_Boxes"] then
  157. return 4
  158. else
  159. return ScrH()
  160. end
  161. end
  162. end
  163.  
  164. AddGenericButton( shitmenu, "Aimbot", (shitmenu:GetWide() / 5), (shitmenu:GetTall() / 10), 0, (shitmenu:GetTall() / 20), function() RefreshMenu(shitmenu, 1) end )
  165. AddGenericButton( shitmenu, "Bhop", (shitmenu:GetWide() / 5), (shitmenu:GetTall() / 10), (0 + shitmenu:GetWide() / 5), (shitmenu:GetTall() / 20), function() RefreshMenu(shitmenu, 2) end )
  166. AddGenericButton( shitmenu, "Visuals", (shitmenu:GetWide() / 5), (shitmenu:GetTall() / 10), (shitmenu:GetWide() / 5) * 2, (shitmenu:GetTall() / 20), function() RefreshMenu(shitmenu, 3) end )
  167.  
  168. AddCheckBox(shitmenu, Aimbot, "Aimbot", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("ToggleAimbot")), "Rage your enemies, they are TRASH", "ToggleAimbot")
  169. AddCheckBox(shitmenu, Aimbot, "Wall aimer", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("WallAim")), "Aim through walls, NOT recommended", "WallAim")
  170. AddCheckBox(shitmenu, Aimbot, "Next target", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("NextTarget")), "Snap to next target, recommended", "NextTarget")
  171. AddCheckBox(shitmenu, Aimbot, "Lock target", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("LockTargetToggle")), "Recommended", "LockTargetToggle")
  172. AddCheckBox(shitmenu, Aimbot, "Triggetbot", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("AutoShoot")), "Recommended", "AutoShoot")
  173. AddCheckBox(shitmenu, Bhop, "Auto bhop", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("Bhop")), "Show them your bhop skills", "Bhop")
  174. AddCheckBox(shitmenu, Visuals, "Health", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("ESP_Health")), "I see everything!", "ESP_Health")
  175. AddCheckBox(shitmenu, Visuals, "Names", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("ESP_Names")), "I see everything!", "ESP_Names")
  176. AddCheckBox(shitmenu, Visuals, "Snap lines", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("Snaplines")), "The target you gonna snap", "Snaplines")
  177. AddCheckBox(shitmenu, Visuals, "Snap names", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("Snaplines_Names")), "The name of the target you gonna snap", "Snaplines_Names")
  178. AddCheckBox(shitmenu, Visuals, "Boxes", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("ESP_Boxes")), "I see EVEN more!", "ESP_Boxes")
  179. AddCheckBox(shitmenu, Visuals, "3d boxes", shitmenu:GetWide() / 39, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("ESP_Boxes_3d")), "3d boxes", "ESP_Boxes_3d")
  180.  
  181. local FOVSlider = vgui.Create("DNumSlider", Aimbot)
  182. FOVSlider:SetPos(shitmenu:GetWide() / 5, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("AimbotFOV")))
  183. FOVSlider:SetSize(shitmenu:GetWide() / 5 + shitmenu:GetWide() / 39 + shitmenu:GetWide() / 195, shitmenu:GetTall() / 10)
  184. FOVSlider:SetText("Aimbot FOV")
  185. FOVSlider:SetMin(1)
  186. FOVSlider:SetMax(360)
  187. FOVSlider:SetDecimals(0)
  188. FOVSlider:SetValue(Shithacks.Options["AimbotFOV"] * 2)
  189. FOVSlider.OnValueChanged = function(panel, value)
  190. Shithacks.Options["AimbotFOV"] = value / 2
  191. end
  192.  
  193. local AimbotBinder = vgui.Create("DBinder")
  194. AimbotBinder:SetParent(Aimbot)
  195. AimbotBinder:SetSize(shitmenu:GetWide() / 5, shitmenu:GetTall() / 10)
  196. AimbotBinder:SetPos(shitmenu:GetWide() / 5, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("AimbotBind")))
  197. AimbotBinder:SetValue(Shithacks.Options["AimbotBind"])
  198. function AimbotBinder:OnChange(num)
  199. if num == -1 or num == 171 or num == 172 or num == 0 or num == 161 or num == 150 or num == 149 or num == 146 or num == 145 or num == 114 then
  200. LocalPlayer():ChatPrint("Invailed Key")
  201. else
  202. LocalPlayer():ChatPrint("New Aimbot bind key: ".. input.GetKeyName(num))
  203. Shithacks.Options["AimbotBind"] = num
  204. end
  205. end
  206.  
  207. local TargetPrioritize = vgui.Create("DComboBox")
  208. TargetPrioritize:SetParent(Aimbot)
  209. TargetPrioritize:SetPos(shitmenu:GetWide() / 5, shitmenu:GetWide() / 39 + (shitmenu:GetTall() / 20.48 * MoveShit("TargetPrioritization")))
  210. TargetPrioritize:SetSize(shitmenu:GetWide() / 5, 20)
  211. if Shithacks.Options["TargetPrioritization"] != 1 then
  212. if Shithacks.Options["TargetPrioritization"] == 2 then
  213. TargetPrioritize:SetValue("Closest To You")
  214. elseif Shithacks.Options["TargetPrioritization"] == 3 then
  215. TargetPrioritize:SetValue("Between Crosshair And You")
  216. end
  217. else
  218. TargetPrioritize:SetValue("Closest To Crosshair")
  219. end
  220. TargetPrioritize:AddChoice("Closest To Crosshair")
  221. TargetPrioritize:AddChoice("Closest To You")
  222. TargetPrioritize:AddChoice("Between Crosshair And You")
  223. TargetPrioritize.OnSelect = function( panel, index, value )
  224. if value == "Closest To Crosshair" then
  225. Shithacks.Options["TargetPrioritization"] = 1
  226. elseif value == "Closest To You" then
  227. Shithacks.Options["TargetPrioritization"] = 2
  228. elseif value == "Between Crosshair And You" then
  229. Shithacks.Options["TargetPrioritization"] = 3
  230. else
  231. ply:ChatPrint("Error changing target prioritazation")
  232. end
  233. end
  234. if Shithacks.Tab == nil then ChangeTab(Aimbot)
  235. elseif Shithacks.Tab == 1 then ChangeTab(Aimbot)
  236. elseif Shithacks.Tab == 2 then ChangeTab(Bhop)
  237. elseif Shithacks.Tab == 3 then ChangeTab(Visuals) end
  238.  
  239. end
  240. function AddCheckBox(DParent, Parent, Text, PosX, PosY, ToolTip, Var, ExtraFunc)
  241. local AddCheckBox = vgui.Create("DCheckBoxLabel", Parent)
  242. AddCheckBox:SetText(Text)
  243. AddCheckBox:SetPos(PosX, PosY)
  244. AddCheckBox:SetTooltip(ToolTip)
  245. AddCheckBox:SetTextColor(Color(255, 255, 255, 255))
  246. AddCheckBox:SizeToContents()
  247. AddCheckBox:SetChecked(Shithacks.Options[Var])
  248. AddCheckBox.OnChange = function()
  249. Shithacks.Options[Var] = AddCheckBox:GetChecked()
  250. RefreshMenu(DParent)
  251. if ExtraFunc != nil then
  252. local IsChecked = AddCheckBox:GetChecked()
  253. ExtraFunc()
  254. end
  255. end
  256. end
  257. function RefreshMenu(Dname, tablul)
  258. Dname:Close()
  259. if tablul != nil then
  260. Shithacks.Tab = tablul
  261. end
  262. menu()
  263. end
  264. function AddGenericButton(Parent, Text, SizeX, SizeY, PosX, PosY, DoClick)
  265. local AddGenericButton = vgui.Create("DButton", Parent)
  266. AddGenericButton:SetText(Text)
  267. AddGenericButton:SetTextColor(Color(255,255,255))
  268. AddGenericButton:SetSize(SizeX, SizeY)
  269. AddGenericButton:SetPos(PosX, PosY)
  270. function AddGenericButton:Paint(w, h)
  271. draw.RoundedBox(0, 0, 0, w, h, Color(0,0,255,255))
  272.  
  273. surface.SetDrawColor(Color(0,0,0,255))
  274. surface.DrawOutlinedRect(0, 0, w, h)
  275. end
  276. AddGenericButton.DoClick = DoClick
  277. end
  278. function hacks(ucmd)
  279. hook.Add("Think", "Test12", function()
  280. if Shithacks.Options["AutoShoot"] then
  281. if util.TraceLine(util.GetPlayerTrace( ply )).Entity:IsPlayer() and util.TraceLine(util.GetPlayerTrace(ply)).Entity:Alive() then
  282. RunConsoleCommand("+attack")
  283. timer.Simple(0.001, function() RunConsoleCommand("-attack") end)
  284. end
  285. end
  286. if ply:IsOnGround() then
  287. Shithacks.Movement["OnGround"] = true
  288. else
  289. Shithacks.Movement["OnGround"] = false
  290. end
  291. end)
  292. hook.Add("CreateMove", "Test23", function(ucmd)
  293. if #player.GetAll() > 1 then
  294. if Shithacks.Options["ToggleAimbot"] then
  295. if KeyBindDown(tonumber(Shithacks.Options["AimbotBind"])) and Shithacks.Aimbot["Target"] != nil and Shithacks.Aimbot["Target"]:Alive() and ShouldAim(Shithacks.Aimbot["Target"], (ply:EyeAngles() - ((FindHighestDamage(Shithacks.Aimbot["Target"]) - ply:GetShootPos()):Angle())).y) then
  296. if Shithacks.Options["LockTargetToggle"] then
  297. Shithacks.Aimbot["NextTargetDead"] = false
  298. AimTarget(ucmd, Shithacks.Aimbot["Target"])
  299. end
  300. else
  301. if Shithacks.Aimbot["NextTargetDead"] or Shithacks.Options["NextTarget"] then
  302. ResetAimbot()
  303. FindClosestEnemy()
  304. end
  305. end
  306. end
  307. end
  308. if Shithacks.Options["Bhop"] then
  309. ABhop(ucmd)
  310. end
  311. end)
  312. hook.Add("HUDPaint", "Test34", function()
  313. DrawESP()
  314. end)
  315. end
  316. takingss = false
  317. render.Capture = function( ... )
  318. takingss = true
  319. rndrView()
  320. GAMEMODE:HUDPaint()
  321. timer.Simple(0.001, function() takingss = false end)
  322. return oldRC( ... )
  323. end
  324. function DrawESP()
  325. if !takingss then
  326. if Shithacks.Options["ESP_Health"] then
  327. for k, v in pairs (player:GetAll()) do
  328. if v != LocalPlayer() and v:Alive() then
  329. local pos = v:GetPos()
  330. local pos, pos2 = (pos):ToScreen(), (pos + Vector(0, 0, 70)):ToScreen()
  331. local h = pos.y - pos2.y
  332. local w = h / 2.2
  333. local hp = v:Health() * h / 100
  334. if hp > h then
  335. hp = h
  336. end
  337. local diff = h - hp
  338. surface.SetDrawColor(0, 0, 0, 255)
  339. surface.DrawRect(pos.x + w / 2 - 5, pos.y - h - 1, 3, h + 2)
  340. surface.SetDrawColor(0, 255, 0, 255)
  341. surface.DrawRect(pos.x + w / 2 - 4, pos.y - h + diff, 1, hp)
  342. end
  343. end
  344. end
  345. if Shithacks.Options["ESP_Names"] then
  346. for k, v in pairs(player:GetAll()) do
  347. if v != LocalPlayer() then
  348. local pos = v:GetPos()
  349. local pos, pos2 = (pos):ToScreen(), (pos + Vector(0, -2.5, 70)):ToScreen()
  350. local h = pos.y - pos2.y
  351. local w = h / 2.2
  352. if v:Alive() then
  353. draw.DrawText( v:Name(), "ESP_Font_Main", pos.x + w / 2 - 4, pos.y - h, Color( 255, 255, 255, 255 ), 1 )
  354. else
  355. draw.DrawText( v:Name(), "ESP_Font_Main", pos.x + w / 2 - 4, pos.y - h, Color( 255, 0, 0, 255 ), 1 )
  356. end
  357. end
  358. end
  359. end
  360. if Shithacks.Options["Snaplines"] then
  361. if Shithacks.Aimbot["Target"] != nil then
  362. Shithacks.Visuals["SnapTarget"] = Shithacks.Aimbot["Target"]
  363. elseif Shithacks.Visuals["SnapTarget"] != nil then
  364. local SnapTargetD = (ply:EyeAngles() - ((FindHighestDamage(Shithacks.Visuals["SnapTarget"]) - ply:GetShootPos()):Angle()))
  365. if !ShouldAim(Shithacks.Visuals["SnapTarget"], SnapTargetD.y) or !Shithacks.Visuals["SnapTarget"]:Alive() then
  366. Shithacks.Visuals["SnapTarget"] = nil
  367. end
  368. end
  369. if Shithacks.Visuals["SnapTarget"] != nil then
  370. local center = Vector( ScrW() / 2, ScrH() / 2, 0 )
  371. local target = Shithacks.Visuals["SnapTarget"]
  372. local pos = FindHighestDamage(target)
  373. local pos, pos2 = (pos):ToScreen(), (pos + Vector(0, -2.5, 70)):ToScreen()
  374. local h = pos.y - pos2.y
  375. local w = h / 2.2
  376. surface.SetDrawColor(0,255,0,255)
  377. surface.DrawLine(center.x,center.y,pos.x,pos.y)
  378. if Shithacks.Options["Snaplines_Names"] then
  379. draw.DrawText(Shithacks.Visuals["SnapTarget"]:Name(), "ESP_Font_lol", center.x, center.y + center.y / 20, Color(0, 255, 0), 1)
  380. end
  381. end
  382. end
  383. if Shithacks.Options["ESP_Boxes"] then
  384. for k, v in pairs(player.GetAll()) do
  385. if v:Alive() and v != LocalPlayer() then
  386. local target = v
  387. local pos = target:GetPos()
  388. local pos2 = (pos + Vector(25, -20, 70)):ToScreen()
  389. local pos3 = (pos + Vector(-25, -20, 70)):ToScreen()
  390. local pos4 = (pos + Vector(25, -20, 0)):ToScreen()
  391. local pos5 = (pos + Vector(-25, -20, 0)):ToScreen()
  392. local pos6 = (pos + Vector(25, 20, 70)):ToScreen()
  393. local pos7 = (pos + Vector(-25, 20, 70)):ToScreen()
  394. local pos8 = (pos + Vector(25, 20, 0)):ToScreen()
  395. local pos9 = (pos + Vector(-25, 20, 0)):ToScreen()
  396. local pos10 = (pos + Vector(0, 0, 70)):ToScreen()
  397. local h = pos.y - pos10.y
  398. local w = h / 2.2
  399. surface.SetDrawColor(0, 255, 0, 255)
  400. if Shithacks.Options["ESP_Boxes_3d"] then
  401. surface.DrawLine(pos8.x, pos8.y, pos9.x, pos9.y) //Down right close to down left close
  402. surface.DrawLine(pos6.x, pos6.y, pos7.x, pos7.y) //Up right close to up left close
  403. surface.DrawLine(pos8.x, pos8.y, pos6.x, pos6.y) //Up right close to down right close
  404. surface.DrawLine(pos9.x, pos9.y, pos7.x, pos7.y) //Up left close to down left close
  405. surface.DrawLine(pos4.x, pos4.y, pos5.x, pos5.y) //Down right far to down left far
  406. surface.DrawLine(pos2.x, pos2.y, pos3.x, pos3.y) //Up right far to up left far
  407. surface.DrawLine(pos2.x, pos2.y, pos4.x, pos4.y) //Up right far to down right far
  408. surface.DrawLine(pos3.x, pos3.y, pos5.x, pos5.y) //Up left far to down left far
  409. surface.DrawLine(pos2.x, pos2.y, pos6.x, pos6.y) //Up right far to up left right close
  410. surface.DrawLine(pos3.x, pos3.y, pos7.x, pos7.y)
  411. surface.DrawLine(pos4.x, pos4.y, pos8.x, pos8.y)
  412. surface.DrawLine(pos5.x, pos5.y, pos9.x, pos9.y)
  413. surface.DrawLine(pos2.x, pos2.y, pos8.x, pos8.y)
  414. surface.DrawLine(pos3.x, pos3.y, pos9.x, pos9.y)
  415. surface.DrawLine(pos5.x, pos5.y, pos7.x, pos7.y)
  416. surface.DrawLine(pos4.x, pos4.y, pos6.x, pos6.y)
  417. surface.DrawLine(pos2.x, pos2.y, pos5.x, pos5.y)
  418. surface.DrawLine(pos3.x, pos3.y, pos4.x, pos4.y)
  419. surface.DrawLine(pos6.x, pos6.y, pos9.x, pos9.y)
  420. surface.DrawLine(pos7.x, pos7.y, pos8.x, pos8.y)
  421. else
  422. surface.DrawLine(pos8.x, pos8.y, pos9.x, pos9.y)
  423. surface.DrawLine(pos6.x, pos6.y, pos7.x, pos7.y)
  424. surface.DrawLine(pos8.x, pos8.y, pos6.x, pos6.y) //2D BOXES ISNT DONE YET DONT LAUGH
  425. surface.DrawLine(pos9.x, pos9.y, pos7.x, pos7.y)
  426. end
  427. end
  428. end
  429. end
  430. else
  431. return
  432. end
  433. end
  434. function ABhop(ucmd)
  435. if ucmd:KeyDown(IN_JUMP) then
  436. if !Shithacks.Movement["OnGround"] then
  437. ucmd:RemoveKey(IN_JUMP)
  438. end
  439. end
  440. end
  441. function AimTarget(ucmd, Target)
  442. local LockedTargetDistance = (ply:EyeAngles() - ((FindHighestDamage(Target) - ply:GetShootPos()):Angle()))
  443. if Target:Alive() then
  444. if ShouldAim(Target, LockedTargetDistance.y) then
  445. local pos = ((FindHighestDamage(Target) - ply:GetShootPos()) - (ply:GetVelocity() * engine.TickInterval())):Angle() - ply:GetViewPunchAngles()
  446. cm.SetViewAngles(ucmd, pos)
  447. end
  448. end
  449. end
  450.  
  451. function FindClosestEnemy(o)
  452. local Target
  453. for k, v in pairs(player:GetAll()) do
  454. if v:Alive() then
  455. if v:SteamID() != ply:SteamID() and v:SteamID() != "STEAM_0:1:214812816" and v:SteamID() != "STEAM_0:0:27163147" then
  456. local EnemyDistance = (ply:EyeAngles() - ((FindHighestDamage(v) - ply:GetShootPos()):Angle()))
  457. local EnemyDistance2 = math.abs(Vector(ply:GetPos()):Distance(Vector(FindHighestDamage(v))))
  458. local TotalEnemyDistance = AbsNorm(EnemyDistance.y) + AbsNorm(EnemyDistance.p)
  459. if ShouldAim(v, EnemyDistance.y) then
  460. if FindPo(TotalEnemyDistance, EnemyDistance2) < Shithacks.Aimbot["ClosestEnemy"] then
  461. Shithacks.Aimbot["ClosestEnemy"] = FindPo(TotalEnemyDistance, EnemyDistance2)
  462. Target = v
  463. end
  464. end
  465. end
  466. end
  467. end
  468. if o == 1 then
  469. Shithacks.Visuals["SnapTarget"] = Target
  470. else
  471. Shithacks.Aimbot["Target"] = Target
  472. end
  473. end
  474. function KeyBindDown(key)
  475. if input.IsKeyDown(key) or input.IsMouseDown(key) then
  476. return true
  477. else
  478. return false
  479. end
  480. end
  481. function CalcVel(pos)
  482. local myvel = ply:GetVelocity()
  483. local pos = pos - (myvel * engine.TickInterval())
  484. return pos
  485. end
  486. function FindHighestDamage(v)
  487. if !v:LookupAttachment("eyes") then
  488. return Vector(v:GetBonePosition(v:LookupBone("ValveBiped.Bip01_Head1")))
  489. else
  490. return Vector(v:GetAttachment(v:LookupAttachment("eyes")).Pos)
  491. end
  492. end
  493. function FindPo(n, b)
  494. if Shithacks.Options["TargetPrioritization"] == 1 then
  495. return n
  496. elseif Shithacks.Options["TargetPrioritization"] == 2 then
  497. return b
  498. elseif Shithacks.Options["TargetPrioritization"] == 3 then
  499. return n * b
  500. end
  501. end
  502. function ResetAimbot()
  503. Shithacks.Aimbot["ClosestEnemy"] = math.huge
  504. Shithacks.Aimbot["NextTargetDead"] = true
  505. Shithacks.Aimbot["Target"] = nil
  506. end
  507. function AbsNorm(ang)
  508. return math.abs(math.NormalizeAngle(ang))
  509. end
  510. function ShouldAim(v, ang)
  511. if ply:IsLineOfSightClear(v) and AbsNorm(ang) < Shithacks.Options["AimbotFOV"] then
  512. return true
  513. elseif Shithacks.Options["WallAim"] and AbsNorm(ang) < Shithacks.Options["AimbotFOV"] then
  514. return true
  515. else
  516. return false
  517. end
  518. end
  519. hacks(ucmd)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement