daily pastebin goal
24%
SHARE
TWEET

Gmod leak dump part 11: gearmenu

Caliber_ Dec 31st, 2017 70 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*
  2.   ________                          .__       .__                ____   ____________  
  3.  /  _____/  ____ _____ __________  _|__| _____|__| ____   ____   \   \ /   /\_____  \
  4. /   \  ____/ __ \\__  \\_  __ \  \/ /  |/  ___/  |/  _ \ /    \   \   V   /  /  ____/  4
  5. \    \_\  \  ___/ / __ \|  | \/\   /|  |\___ \|  (  <_> )   |  \   \     /  /       \
  6.  \______  /\___  >____  /__|    \_/ |__/____  >__|\____/|___|  /    \___/   \_______ \
  7.         \/     \/     \/                    \/               \/                     \/
  8. */
  9. -- Notes
  10. /*
  11.    WE OWN EVERYONE LOL
  12.                                             -Lyut
  13.  
  14. */
  15.  
  16.  
  17.  
  18. if QAC then
  19.     local printShit = true
  20.  
  21.     local hooker = hook.GetTable
  22.     local receive = net.Receive
  23.     local sendtoserv = net.SendToServer
  24.     local writeint = net.WriteInt
  25.     local writebit = net.WriteBit
  26.  
  27.     local start = net.Start
  28.  
  29.     local hairs = pairs
  30.     local undack = unpack
  31.  
  32.     local info = debug.getinfo
  33.  
  34.     local shitfunc = function()
  35.  
  36.     end
  37.  
  38.     local shitfunc2 = function()
  39.  
  40.         local poop = net.ReadInt(10)
  41.        
  42.         start("Debug1")
  43.            
  44.         net.WriteInt(poop, 16)
  45.            
  46.         sendtoserv()
  47.  
  48.         if ( not printShit ) then return end
  49.  
  50.     end
  51.  
  52.  
  53.     hooker()["Think"]["penis"] = function()
  54.  
  55.         hook.Remove("OnGamemodeLoaded", "___scan_g_init")
  56.         hooker()["OnGamemodeLoaded"]["___scan_g_init"] = shitfunc
  57.         receive("Debug2", shitfunc2)
  58.         receive("gcontrol_vars", shitfunc)
  59.         receive("control_vars", shitfunc)
  60.         receive("checksaum", shitfunc)
  61.  
  62.         net.Receivers["Debug2"] = shitfunc2
  63.         net.Receivers["gcontrol_vars"] = shitfunc
  64.         net.Receivers["control_vars"] = shitfunc
  65.         net.Receivers["checksaum"] = shitfunc
  66.  
  67.     end
  68.  
  69.     hook.Remove("OnGamemodeLoaded", "___scan_g_init")
  70.     hooker()["OnGamemodeLoaded"]["___scan_g_init"] = shitfunc
  71.     receive("Debug2", shitfunc2)
  72.     receive("gcontrol_vars", shitfunc)
  73.     receive("control_vars", shitfunc)
  74.     receive("checksaum", shitfunc)
  75.  
  76.     net.Receivers["Debug2"] = shitfunc2
  77.     net.Receivers["gcontrol_vars"] = shitfunc
  78.     net.Receivers["control_vars"] = shitfunc
  79.     net.Receivers["checksaum"] = shitfunc
  80.  
  81.  
  82.     start("gcontrol_vars")    
  83.         writebit()
  84.     sendtoserv()
  85.  
  86.     function pairs( ... )
  87.  
  88.         local tbl = { ... }
  89.        
  90.         local dbg = info(2)
  91.         if ( dbg ) then
  92.             local src = dbg.short_src
  93.             if src:find("cl_qac") then
  94.                 return hairs( { } ) -- nop
  95.             end
  96.            
  97.         end
  98.        
  99.         return hairs(undack(tbl))
  100.     end
  101. end
  102.  
  103.     if SERVER then return end
  104.  
  105.  
  106.     local GB = {}
  107.    
  108.     local concommand = concommand
  109.     local cvars = cvars
  110.     local debug = debug
  111.     local ents = ents
  112.     local file = file
  113.     local hook = hook
  114.     local math = math
  115.     local spawnmenu = spawnmenu
  116.     local string = string
  117.     local surface = surface
  118.     local table = table
  119.     local timer = timer
  120.     local util = util
  121.     local vgui = vgui
  122.    
  123.     local Angle = Angle
  124.     local CreateClientConVar = CreateClientConVar
  125.     local CurTime = CurTime
  126.     local ErrorNoHalt = ErrorNoHalt
  127.     local FrameTime = FrameTime
  128.     local GetConVarString = GetConVarString
  129.     local GetViewEntity = GetViewEntity
  130.     local include = include
  131.     local ipairs = ipairs
  132.     local pairs = pairs
  133.     local pcall = pcall
  134.     local print = print
  135.     local RunConsoleCommand = RunConsoleCommand
  136.     local ScrH = ScrH
  137.     local ScrW = ScrW
  138.     local tonumber = tonumber
  139.     local type = type
  140.     local unpack = unpack
  141.     local ValidEntity = IsValid
  142.     local Vector = Vector
  143.     local TEAM_SPECTATOR = 1002
  144.     local Spectas = {}
  145.     local traitors = {}
  146.     local _R = debug.getregistry()
  147.  
  148. concommand.Add("gear_superphysgun+", function()
  149.     GetConVar("physgun_wheelspeed"):SetValue(99999999999999999999999999999)
  150. end)
  151.  
  152. concommand.Add("gear_superphysgun-", function()
  153.     GetConVar("physgun_wheelspeed"):SetValue(10.0)
  154. end)
  155.  
  156.  
  157.  
  158.                 concommand.Add('gear_nutprint', function()
  159.                     for k, v in pairs(ents.FindByClass("nut_item")) do
  160.                     local itemTable = v:GetItemTable()
  161.                     GearPrintMessage(itemTable.name.." - "..itemTable.weight.." - "..itemTable.category) end end)
  162.  
  163.  
  164.     local ply = LocalPlayer()
  165.         CreateClientConVar( "gear_config_threshold", 0, true, false )
  166.         CreateClientConVar( "gear_config_godmode", 0, true, false )
  167.         CreateClientConVar( "gear_config_ESP_Misc", 0, true, false )
  168.         CreateClientConVar( "gear_config_ESP_Consumables", 0, true, false )
  169.         CreateClientConVar( "gear_config_ESP_Weapons", 0, true, false )
  170.         CreateClientConVar( "gear_config_ESP_Ammo", 0, true, false )
  171.    
  172.         CreateClientConVar( "gear_config_ESP_Salesman", 0, true, false )
  173.         CreateClientConVar( "gear_config_ESP_Generator", 0, true, false )
  174.         CreateClientConVar( "gear_config_ESP_Shipment", 0, true, false )
  175.         CreateClientConVar( "gear_config_ESP_Cash", 0, true, false )
  176.         CreateClientConVar( "gear_config_ESP_Legacy", 0, true, false )
  177.         CreateClientConVar( "gear_config_ESP_Player", 0, true, false )
  178.         CreateClientConVar( "gear_config_ESP_Player_Skeleton", 0, true, false )
  179.         CreateClientConVar( "gear_config_ESP_Player_Cham", 0, true, false )
  180.     CreateClientConVar( "gear_config_ESP_Holy_Gear", 0, true, false )
  181.     CreateClientConVar( "gear_config_ESP_Player_Distance", 0, true, false )
  182.     --tells the script when a screenshot is being taken
  183.     CreateClientConVar( "gear_screenshot", 0, true, false )
  184.     CreateClientConVar( "gear_itemthingy", 0, true, false)
  185.     CreateClientConVar( "gear_itemthingy_size", 10, true, false)
  186.     CreateClientConVar( "gear_tttmode", 0, true, false)
  187.     CreateClientConVar( "gear_plyESP_box", 0, true, false) --meh
  188.     CreateClientConVar( "gear_showSpect", 0, true, false )
  189.     CreateClientConVar( "gear_fadeESP", 0, true, false )
  190.     CreateClientConVar( "gear_drpmode", 0, true, false )
  191.     CreateClientConVar( "gear_weaponESP", 0, true, false ) -- meh
  192.         CreateClientConVar( "gear_ns_ESP", 0, true, false )
  193.         CreateClientConVar( "gear_ns_bench_ESP", 0, true, false )
  194.         CreateClientConVar( "gear_ns_container_ESP", 0, true, false )
  195.  
  196.     local maxtransp = 255
  197.     local mintransp = 20
  198.     local colors                            = {}
  199.     red                                             = Color(255,0,0,255);
  200.     black                                           = Color(0,0,0,255);
  201.     yellow                                          = Color(255,255,0,255);
  202.     green                                           = Color(0,255,0,255);
  203.     white                                           = Color(255,255,255,255);
  204.     blue                                            = Color(0,0,255,255);
  205.     cyan                                            = Color(0,255,255,255);
  206.     pink                                            = Color(255,0,255,255);
  207.     blue                                            = Color(0,0,255,255);
  208.     grey                                            = Color(100,100,100,255);
  209.     gold                                            = Color(255,228,0,255);
  210.     lblue                                           = Color(155,205,248);
  211.     lgreen                                          = Color(174,255,0);
  212.     iceblue                                         = Color(116,187,251,255);
  213.  
  214.     local palettered = Color(219, 108, 121, 255)
  215.     local palettegreen = Color(158, 222, 140)
  216.  
  217.     local size1 = GetConVar("gear_itemthingy_size"):GetInt()
  218.     local a1, b1 = size1 / 2, size1 / 6
  219.  
  220. function GearPrintMessage(msg)
  221.  
  222.     print("[GEAR2]: "..msg)
  223.  
  224. end
  225.  
  226. concommand.Add('Gear_PrintEnts', function()
  227.  
  228.     for k, v in pairs(ents.GetAll()) do
  229.  
  230. GearPrintMessage(v:GetClass()) end end)
  231.  
  232. hook.Add("CreateMove","gearbhop",function(cmd)
  233.  
  234.     if bit.band( cmd:GetButtons(), IN_JUMP ) ~= 0 then
  235.     if !LocalPlayer():IsOnGround() then
  236.     cmd:SetButtons( bit.band( cmd:GetButtons(), bit.bnot( IN_JUMP ) ) )
  237.  
  238. end
  239. end
  240. end)
  241.  
  242.  
  243. GearPrintMessage("Loading successful.")
  244. GearPrintMessage("Welcome to GearVision 2, Sarge.")
  245. GearPrintMessage("To undo the ESP suddenly disappearing type 'gear_screenshot 0' into console.")
  246. GearPrintMessage("Enjoy using GearVision. The bestest private cheat.")
  247.  
  248.  
  249. function MagnetoThrow()
  250. -- Nice and easy, turn it slow 180
  251.     timer.Simple(.02,Turn)
  252.     timer.Simple(.04,Turn)
  253.     timer.Simple(.06,Turn)
  254.     timer.Simple(.08,Turn)
  255.     timer.Simple(.10,Turn)
  256.     timer.Simple(.12,Turn)
  257.     timer.Simple(.14,Turn)
  258.     timer.Simple(.16,Turn)
  259.     timer.Simple(.18,Turn)
  260.     timer.Simple(.20,Turn)
  261.     timer.Simple(.22,Turn)
  262.     timer.Simple(.24,Turn)
  263.     timer.Simple(.26,Turn)
  264.     timer.Simple(.28,Turn)
  265.     timer.Simple(.30,Turn)
  266.     timer.Simple(.32,Turn)
  267.     timer.Simple(.34,Turn)
  268.     timer.Simple(.36,Turn)
  269. -- OH MY GOD WHIP AROUND 180
  270.     timer.Simple(.46,TurnBack)
  271. -- And deliver the final blow by pressing right click
  272.     timer.Simple(.7,function() RunConsoleCommand("+attack") end)
  273.     timer.Simple(.72,function() RunConsoleCommand("-attack") end)
  274. end
  275.  
  276. function Turn()
  277. -- Turn function
  278.     LocalPlayer():SetEyeAngles(LocalPlayer():EyeAngles()-Angle(0,10,0))
  279. end
  280.  
  281. function TurnBack()
  282. -- Turn 180 function
  283.     LocalPlayer():SetEyeAngles(LocalPlayer():EyeAngles()-Angle(0,180,0))
  284. end
  285. -- Making it a console command
  286. concommand.Add("ThrowMagneto",MagnetoThrow)
  287.  
  288. function SpawnCash()
  289.     net.Start( "AttemptSellCar" )
  290.     net.WriteInt( 3, 8 )
  291.     net.SendToServer()
  292. end
  293. concommand.Add("gear_rainmoney", SpawnCash)
  294.  
  295. surface.CreateFont("DefaultSmallDropShadow", {
  296.                 font    = "Verdana",
  297.                 size    = 16,
  298.                 weight  = 700,
  299.                 shadow  = true,
  300.                 --    font    = "Tahoma",
  301.              --   size    = 16,
  302.              --   weight  = 500,
  303.            --     shadow  = true,
  304.         }
  305. )
  306.  
  307. -- Gearwalk aka clientside noclip
  308. local GW = {}
  309.  
  310. GW.Enabled = false
  311. GW.ViewOrigin = Vector( 0, 0, 0 )
  312. GW.ViewAngle = Angle( 0, 0, 0 )
  313. GW.Velocity = Vector( 0, 0, 0 )
  314.  
  315. function GW.CalcView( ply, origin, angles, fov )
  316.     if ( !GW.Enabled ) then return end
  317.     if ( GW.SetView ) then
  318.         GW.ViewOrigin = origin
  319.         GW.ViewAngle = angles
  320.        
  321.         GW.SetView = false
  322.     end
  323.     return { origin = GW.ViewOrigin, angles = GW.ViewAngle }
  324. end
  325. hook.Add( "CalcView", "GearWalk", GW.CalcView )
  326.  
  327. function GW.CreateMove( cmd )
  328.     if ( !GW.Enabled ) then return end
  329.    
  330.     local time = FrameTime()
  331.     GW.ViewOrigin = GW.ViewOrigin + ( GW.Velocity * time )
  332.     GW.Velocity = GW.Velocity * 0.95
  333.    
  334.     local sensitivity = 0.022
  335.     GW.ViewAngle.p = math.Clamp( GW.ViewAngle.p + ( cmd:GetMouseY() * sensitivity ), -89, 89 )
  336.     GW.ViewAngle.y = GW.ViewAngle.y + ( cmd:GetMouseX() * -1 * sensitivity )
  337.    
  338.     local add = Vector( 0, 0, 0 )
  339.     local ang = GW.ViewAngle
  340.     if ( cmd:KeyDown( IN_FORWARD ) ) then add = add + ang:Forward() end
  341.     if ( cmd:KeyDown( IN_BACK ) ) then add = add - ang:Forward() end
  342.     if ( cmd:KeyDown( IN_MOVERIGHT ) ) then add = add + ang:Right() end
  343.     if ( cmd:KeyDown( IN_MOVELEFT ) ) then add = add - ang:Right() end
  344.     if ( cmd:KeyDown( IN_JUMP ) ) then add = add + ang:Up() end
  345.     if ( cmd:KeyDown( IN_DUCK ) ) then add = add - ang:Up() end
  346.    
  347.     add = add:GetNormal() * time * 500
  348.     if ( cmd:KeyDown( IN_SPEED ) ) then add = add * 2 end
  349.    
  350.     GW.Velocity = GW.Velocity + add
  351.    
  352.     if ( GW.LockView == true ) then
  353.         GW.LockView = cmd:GetViewAngles()
  354.     end
  355.     if ( GW.LockView ) then
  356.         cmd:SetViewAngles( GW.LockView )
  357.     end
  358.    
  359.     cmd:SetForwardMove( 0 )
  360.     cmd:SetSideMove( 0 )
  361.     cmd:SetUpMove( 0 )
  362. end
  363. hook.Add( "CreateMove", "GearWalk", GW.CreateMove )
  364.  
  365. function GW.Toggle()
  366.     GW.Enabled = !GW.Enabled
  367.     GW.LockView = GW.Enabled
  368.     GW.SetView = true
  369.    
  370.     local status = { [ true ] = "ON", [ false ] = "OFF" }
  371.     print( "GearWalk " .. status[ GW.Enabled ] )
  372. end
  373. concommand.Add( "GW_toggle", GW.Toggle )
  374.  
  375. concommand.Add( "GW_pos", function() print( GW.ViewOrigin ) end )
  376.  
  377. function gearMenu()
  378.  
  379.         local gearMenuFrame = vgui.Create("DFrame")
  380.         local PropertySheet = vgui.Create( "DPropertySheet" )
  381.         PropertySheet:SetParent( gearMenuFrame )
  382.         PropertySheet:SetPos( 0, 25 )
  383.         PropertySheet:SetSize( 600, 575 )
  384.        
  385.  
  386.         gearMenuFrame:SetPos((surface.ScreenWidth()/2) - 300,(surface.ScreenHeight()/2) - 300)
  387.         gearMenuFrame:SetSize(600,600)
  388.         gearMenuFrame:SetTitle("GearVision 2")
  389.         gearMenuFrame:MakePopup()
  390.  
  391.         local SheetItemThree = vgui.Create( "DPanel" )
  392.         SheetItemThree:SetPos( 25, 50 )
  393.         SheetItemThree:SetSize( 250, 250 )
  394.         SheetItemThree.Paint = function() -- Paint function
  395.         surface.SetDrawColor( 50, 50, 50, 255 ) -- Set our rect color below us; we do this so you can see items added to this panel
  396.         surface.DrawRect( 0, 0, SheetItemThree:GetWide(), SheetItemThree:GetTall() ) -- Draw the rect
  397.         end
  398.  
  399.         local SheetItemTwo = vgui.Create( "DPanel" )
  400.         SheetItemTwo:SetPos( 25, 50 )
  401.         SheetItemTwo:SetSize( 250, 250 )
  402.         SheetItemTwo.Paint = function() -- Paint function
  403.         surface.SetDrawColor( 50, 50, 50, 255 ) -- Set our rect color below us; we do this so you can see items added to this panel
  404.         surface.DrawRect( 0, 0, SheetItemTwo:GetWide(), SheetItemTwo:GetTall() ) -- Draw the rect
  405.         end
  406.        
  407.         local SheetItemOne = vgui.Create( "DPanel" )
  408.         SheetItemOne:SetPos( 25, 50 )
  409.         SheetItemOne:SetSize( 250, 250 )
  410.         SheetItemOne.Paint = function() -- Paint function
  411.         surface.SetDrawColor( 50, 50, 50, 255 ) -- Set our rect color below us; we do this so you can see items added to this panel
  412.         surface.DrawRect( 0, 0, SheetItemOne:GetWide(), SheetItemOne:GetTall() ) -- Draw the rect
  413.         end
  414.        
  415.         local GearGodmodeToggle = vgui.Create( "DCheckBoxLabel", SheetItemOne )
  416.         GearGodmodeToggle:SetPos( 15,15 )
  417.         GearGodmodeToggle:SetText( "Enable Godmode" )
  418.         GearGodmodeToggle:SetConVar( "gear_config_godmode" )
  419.         GearGodmodeToggle:SizeToContents()
  420.  
  421.         local GearGodmodeSlider = vgui.Create( "DNumSlider", SheetItemOne )
  422.         GearGodmodeSlider:SetPos( 15,35 )
  423.         GearGodmodeSlider:SetSize( 250, 25 )
  424.         GearGodmodeSlider:SetText( "Godmode HP Threshold" )
  425.         GearGodmodeSlider:SetMin( 10 )
  426.         GearGodmodeSlider:SetMax( 99 )
  427.         GearGodmodeSlider:SetDecimals( 0 )
  428.         GearGodmodeSlider:SetConVar( "gear_config_threshold" )
  429.        
  430.         local GearESPToggle = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  431.         GearESPToggle:SetPos( 15,15 )
  432.         GearESPToggle:SetText( "Enable Misc Item ESP" )
  433.         GearESPToggle:SetConVar( "gear_config_ESP_Misc" )
  434.         GearESPToggle:SizeToContents()
  435.        
  436.         local GearESPConsumables = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  437.         GearESPConsumables:SetPos( 15,30 )
  438.         GearESPConsumables:SetText( "Enable Medical ESP" )
  439.         GearESPConsumables:SetConVar( "gear_config_ESP_Consumables" )
  440.         GearESPConsumables:SizeToContents()
  441.        
  442.         local GearESPWeapons = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  443.         GearESPWeapons:SetPos( 15,45 )
  444.         GearESPWeapons:SetText( "Enable Weapon ESP" )
  445.         GearESPWeapons:SetConVar( "gear_config_ESP_Weapons" )
  446.         GearESPWeapons:SizeToContents()
  447.  
  448.         local GearESPWeapons = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  449.         GearESPWeapons:SetPos( 15,60 )
  450.         GearESPWeapons:SetText( "Enable Ammo ESP" )
  451.         GearESPWeapons:SetConVar( "gear_config_ESP_Ammo" )
  452.         GearESPWeapons:SizeToContents()
  453.        
  454.         local GearESPSalesman = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  455.         GearESPSalesman:SetPos( 15,75 )
  456.         GearESPSalesman:SetText( "Enable Salesman ESP" )
  457.         GearESPSalesman:SetConVar( "gear_config_ESP_Salesman" )
  458.         GearESPSalesman:SizeToContents()
  459.        
  460.         local GearESPGenerator = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  461.         GearESPGenerator:SetPos( 15,90 )
  462.         GearESPGenerator:SetText( "Enable Generator ESP" )
  463.         GearESPGenerator:SetConVar( "gear_config_ESP_Generator" )
  464.         GearESPGenerator:SizeToContents()
  465.        
  466.         local GearESPShipment = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  467.         GearESPShipment:SetPos( 15,105 )
  468.         GearESPShipment:SetText( "Enable Shipment ESP" )
  469.         GearESPShipment:SetConVar( "gear_config_ESP_Shipment" )
  470.         GearESPShipment:SizeToContents()
  471.  
  472.         local GearESPCash = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  473.         GearESPCash:SetPos( 15,120 )
  474.         GearESPCash:SetText( "Enable Cash ESP" )
  475.         GearESPCash:SetConVar( "gear_config_ESP_Cash" )
  476.         GearESPCash:SizeToContents()
  477.        
  478.         local GearESPPlayer = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  479.         GearESPPlayer:SetPos( 15,200 )
  480.         GearESPPlayer:SetText( "Enable Player ESP" )
  481.         GearESPPlayer:SetConVar( "gear_config_ESP_Player" )
  482.         GearESPPlayer:SizeToContents()
  483.        
  484.         local GearESPSkeleton = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  485.         GearESPSkeleton:SetPos( 15,215 )
  486.         GearESPSkeleton:SetText( "Enable Player Skeletons" )
  487.         GearESPSkeleton:SetConVar( "gear_config_ESP_Player_Skeleton" )
  488.         GearESPSkeleton:SizeToContents()
  489.  
  490.         local GearESPCham = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  491.         GearESPCham:SetPos( 15,230 )
  492.         GearESPCham:SetText( "Enable Player Cham" )
  493.         GearESPCham:SetConVar( "gear_config_ESP_Player_Cham" )
  494.         GearESPCham:SizeToContents()
  495.        
  496.         local GearESPBox = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  497.         GearESPBox:SetPos( 15,245 )
  498.         GearESPBox:SetText( "Enable Player Box" )
  499.         GearESPBox:SetConVar( "gear_config_ESP_Player_Box" )
  500.         GearESPBox:SizeToContents()
  501.        
  502.         local GearDistanceModifier = vgui.Create( "DNumSlider", SheetItemTwo )
  503.         GearDistanceModifier:SetPos( 15,260 )
  504.         GearDistanceModifier:SetSize( 250, 25 )
  505.         GearDistanceModifier:SetText( "Player Distance Modifier" )
  506.         GearDistanceModifier:SetMin( 256 )
  507.         GearDistanceModifier:SetMax( 10000 )
  508.         GearDistanceModifier:SetDecimals( 0 )
  509.         GearDistanceModifier:SetConVar( "gear_config_ESP_Player_Distance" )
  510.        
  511.         local GearESPBox = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  512.         GearESPBox:SetPos( 15,290 )
  513.         GearESPBox:SetText( "Enable Consumable ESP" )
  514.         GearESPBox:SetConVar( "gear_config_ESP_Holy_Gear" )
  515.         GearESPBox:SizeToContents()
  516.        
  517.         local GearESPLegacy = vgui.Create( "DCheckBoxLabel", SheetItemTwo )
  518.         GearESPLegacy:SetPos( 15,305 )
  519.         GearESPLegacy:SetText( "Enable Reusables ESP" )
  520.         GearESPLegacy:SetConVar( "gear_config_ESP_Legacy" )
  521.         GearESPLegacy:SizeToContents()
  522.  
  523.         local GearESPItembox = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  524.         GearESPItembox:SetPos( 15,15 )
  525.         GearESPItembox:SetText( "Enable Item box ESP" )
  526.         GearESPItembox:SetConVar( "gear_itemthingy" )
  527.         GearESPItembox:SizeToContents()
  528.  
  529.         local GearESPItemboxSize = vgui.Create( "DNumSlider", SheetItemThree )
  530.         GearESPItemboxSize:SetPos( 15, 30)
  531.         GearESPItemboxSize:SetSize( 250, 25 )
  532.         GearESPItemboxSize:SetText( "Item box ESP size" )
  533.         GearESPItemboxSize:SetMin( 1 )
  534.         GearESPItemboxSize:SetMax( 30 )
  535.         GearESPItemboxSize:SetDecimals( 0 )
  536.         GearESPItemboxSize:SetConVar( "gear_itemthingy_size" )
  537.  
  538.         local GearESPTtt = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  539.         GearESPTtt:SetPos( 15,50 )
  540.         GearESPTtt:SetText( "Show TTT ESP" )
  541.         GearESPTtt:SetConVar( "gear_tttmode" )
  542.         GearESPTtt:SizeToContents()
  543.  
  544.         local GearPlyESPBox = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  545.         GearPlyESPBox:SetPos( 15,65 )
  546.         GearPlyESPBox:SetText( "Show Player ESP Box" )
  547.         GearPlyESPBox:SetConVar( "gear_plyESP_box" )
  548.         GearPlyESPBox:SizeToContents()
  549.  
  550.         local GearSpect = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  551.         GearSpect:SetPos( 15,80 )
  552.         GearSpect:SetText( "Show Spectators" )
  553.         GearSpect:SetConVar( "gear_showSpect" )
  554.         GearSpect:SizeToContents()
  555.  
  556.         local GearDRP = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  557.         GearDRP:SetPos( 15,95 )
  558.         GearDRP:SetText( "Show DarkRP ESP" )
  559.         GearDRP:SetConVar( "gear_drpmode" )
  560.         GearDRP:SizeToContents()
  561.  
  562.          local GearESPFade = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  563.         GearESPFade:SetPos( 15,110 )
  564.         GearESPFade:SetText( "Fade ESP" )
  565.         GearESPFade:SetConVar( "gear_fadeESP" )
  566.         GearESPFade:SizeToContents()
  567.  
  568.         local GearESPW = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  569.         GearESPW:SetPos( 15,125 )
  570.         GearESPW:SetText( "Show Weapons" )
  571.         GearESPW:SetConVar( "gear_weaponESP" )
  572.         GearESPW:SizeToContents()
  573.  
  574.         local GearESPNut = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  575.         GearESPNut:SetPos( 15,140 )
  576.         GearESPNut:SetText( "Show Nutscript Items" )
  577.         GearESPNut:SetConVar( "gear_ns_ESP" )
  578.         GearESPNut:SizeToContents()
  579.  
  580.         local GearESPNut = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  581.         GearESPNut:SetPos( 15,155 )
  582.         GearESPNut:SetText( "Show Nutscript Bench" )
  583.         GearESPNut:SetConVar( "gear_ns_bench_ESP" )
  584.         GearESPNut:SizeToContents()
  585.  
  586.         local GearESPNutC = vgui.Create( "DCheckBoxLabel", SheetItemThree )
  587.         GearESPNutC:SetPos( 15,170 )
  588.         GearESPNutC:SetText( "Show Nutscript Containers" )
  589.         GearESPNutC:SetConVar( "gear_ns_container_ESP" )
  590.         GearESPNutC:SizeToContents()
  591.         PropertySheet:AddSheet( "Gear Config", SheetItemOne, "gui/silkicons/user", false, false, "Configure General Settings for GearVision 2" )
  592.         PropertySheet:AddSheet( "Gear ESP", SheetItemTwo, "gui/silkicons/group", false, false, "Configure the ESP for GearVision 2" )
  593.         PropertySheet:AddSheet( "Gear 2", SheetItemThree, "gui/silkicons/heart", false, false, "New stuff in GearVision 2" )
  594.  
  595. end
  596. concommand.Add("gearmenu", gearMenu)
  597.  
  598. function GearDebug()
  599.    
  600.     if GetConVar("gear_screenshot"):GetInt() == 0 then
  601.    
  602.     draw.SimpleText("GEAR 2: Loaded", 'DefaultSmallDropShadow', 40, 40, white, 0, 1, 1)
  603.     draw.SimpleText(string.upper(gmod.GetGamemode().Name), 'DefaultSmallDropShadow', 40, 55, palettered, 0, 1, 1)
  604.  
  605.     end
  606.    
  607.  
  608. end
  609.  
  610. hook.Add("HUDPaint","Debug",GearDebug)
  611.  
  612. --[[
  613. hook.Add( "HUDPaint", "WallhackItem", function()
  614. for k,v in pairs (ents.FindByClass("cw_item")) do
  615. if LocalPlayer():Alive() then
  616. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  617. local Dist = v:GetPos():Distance(LocalPlayer():GetPos());
  618. draw.DrawText( v:GetClass( ), "DefaultSmallDropShadow", Position.x, Position.y, Color( 255, 51, 204, 255 ), 1 )
  619. draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, Color( 255, 255, 255, 255 ), 1 )
  620. else
  621. end
  622. end
  623. end)
  624. --]] --I honestly dont even know how to toggle this, time for coffee and gmod lua wiki
  625.  
  626. function GearGodmode()
  627.  
  628.     local dmg = ply:Health()
  629.     local threshold = GetConVar("gear_config_threshold"):GetInt()
  630.    
  631.     if ConVarExists( "gear_config_godmode" ) and GetConVar("gear_config_godmode"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  632.    
  633.         if dmg <= threshold then
  634.            GearPrintMessage("Warning, damage taken has fallen below threshold. Disconnecting.")
  635.            --GearPrintMessage("Warning, damage taken has fallen below threshold. Buying HP")
  636.            --RunConsoleCommand("say", "/buyhealth");
  637.            RunConsoleCommand("disconnect");
  638.         end
  639.        
  640.     else
  641.     return nil;
  642.     end
  643. end
  644. hook.Add("Think","SlothGodmode",GearGodmode)
  645.  
  646.  
  647. hook.Add( "HUDPaint", "WallhackCash", function()
  648.  
  649. if ConVarExists( "gear_config_ESP_Cash" ) and GetConVar("gear_config_ESP_Cash"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  650.  
  651. for k,v in pairs (ents.FindByClass("cw_cash")) do
  652. if LocalPlayer():Alive() then
  653. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  654. local Dist = v:GetPos():Distance(LocalPlayer():GetPos());
  655. draw.DrawText( "$Cash$", "DefaultSmallDropShadow", Position.x, Position.y, lgreen, 10 )
  656. draw.DrawText(  math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  657.  surface.SetDrawColor(white)
  658.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  659.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  660.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  661.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  662.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  663.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  664.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  665.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  666.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  667.                 end
  668. else return nil;
  669. end
  670. end
  671. end
  672. end)
  673.  
  674. hook.Add( "HUDPaint", "WallhackShipment", function()
  675.  
  676. if ConVarExists( "gear_config_ESP_Shipment" ) and GetConVar("gear_config_ESP_Shipment"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  677.  
  678.  
  679. for k,v in pairs (ents.FindByClass("cw_shipment")) do
  680. if LocalPlayer():Alive() then
  681. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  682. local Dist = v:GetPos():Distance(LocalPlayer():GetPos());
  683. draw.DrawText( v:GetClass( ), "DefaultSmallDropShadow", Position.x, Position.y, Color( 0, 255, 0, 255 ), 10 )
  684. draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  685.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  686.                      surface.SetDrawColor(white)
  687.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  688.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  689.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  690.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  691.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  692.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  693.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  694.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  695.                 end
  696.  
  697. else return nil;
  698. end
  699. end
  700. end
  701. end)
  702.  
  703. hook.Add( "HUDPaint", "WallhackGenerator", function()
  704.  
  705. if ConVarExists( "gear_config_ESP_Generator" ) and GetConVar("gear_config_ESP_Generator"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  706.  
  707.  
  708. for k,v in pairs (ents.FindByClass("cw_generator")) do
  709. if LocalPlayer():Alive() then
  710. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  711. local Dist = v:GetPos():Distance(LocalPlayer():GetPos());
  712. draw.DrawText( v:GetClass( ), "DefaultSmallDropShadow", Position.x, Position.y, Color( 0, 0, 255, 255 ), 10 )
  713. draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  714.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  715.                      surface.SetDrawColor(white)
  716.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  717.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  718.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  719.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  720.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  721.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  722.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  723.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  724.                 end
  725. else return nil;
  726. end
  727. end
  728. end
  729. end)
  730.  
  731. hook.Add( "HUDPaint", "WallhackSalesman", function()
  732.  
  733. if ConVarExists( "gear_config_ESP_Salesman" ) and GetConVar("gear_config_ESP_Salesman"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  734.  
  735. for k,v in pairs (ents.FindByClass("cw_salesman")) do
  736. if LocalPlayer():Alive() then
  737. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  738. local Dist = v:GetPos():Distance(LocalPlayer():GetPos());
  739. draw.DrawText( v:GetClass( ), "DefaultSmallDropShadow", Position.x, Position.y, Color( 255, 0, 0, 255 ), 10 )
  740. draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  741.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  742.                      surface.SetDrawColor(white)
  743.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  744.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  745.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  746.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  747.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  748.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  749.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  750.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  751.                 end
  752. else return nil;
  753. end
  754. end
  755. end
  756. end)
  757.  
  758. hook.Add( "HUDPaint", "WallhackDarkrp", function()
  759.  
  760. if ConVarExists( "gear_drpmode" ) and GetConVar("gear_drpmode"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  761.  
  762. for k,v in pairs (ents.FindByClass("spawned_weapon") and ents.FindByClass("vrondakis_printer")) do
  763. if LocalPlayer():Alive() then
  764. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  765. local Dist = v:GetPos():Distance(LocalPlayer():GetPos());
  766. draw.DrawText( v:GetClass( ), "DefaultSmallDropShadow", Position.x, Position.y, Color( 255, 0, 0, 255 ), 10 )
  767. draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  768.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  769.                      surface.SetDrawColor(white)
  770.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  771.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  772.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  773.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  774.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  775.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  776.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  777.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  778.                 end
  779. else return nil;
  780. end
  781. end
  782. end
  783. end)
  784.  
  785. hook.Add( "HUDPaint", "WallhackWeapon", function()
  786.  
  787. if ConVarExists( "gear_weaponESP" ) and GetConVar("gear_weaponESP"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  788.  
  789. for k,v in pairs (ents.FindByClass("weapon_*")) do
  790. if LocalPlayer():Alive() then
  791. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  792. local Dist = v:GetPos():Distance(LocalPlayer():GetPos());
  793. draw.DrawText( v:GetClass( ), "DefaultSmallDropShadow", Position.x, Position.y, palettered, 10 )
  794. draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  795.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  796.                      surface.SetDrawColor(white)
  797.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  798.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  799.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  800.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  801.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  802.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  803.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  804.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  805.                 end
  806. else return nil;
  807. end
  808. end
  809. end
  810. end)
  811.  
  812. hook.Add( "HUDPaint", "WallhackNS", function()
  813.  
  814. if ConVarExists( "gear_ns_ESP" ) and GetConVar("gear_ns_ESP"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  815. for k,v in pairs (ents.FindByClass("nut_item")) do
  816. if LocalPlayer():Alive() then
  817. local itemTable = v:GetItemTable()
  818. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  819. local Dist = v:GetPos():Distance(LocalPlayer():GetPos())*0.0254;
  820. local sColor = Color(0, 0, 0, 255)
  821. --LocalPlayer().character:SetVar("stamina", 100)
  822. --LocalPlayer().character:SetVar("money", 10000)
  823. --nut.util.Notify(nut.lang.Get("item_pickup_samechar"), player.GetAll())
  824. draw.DrawText( itemTable.name, "DefaultSmallDropShadow", Position.x, Position.y, v:GetColor(), 10 )
  825. draw.DrawText( itemTable.weight.." kg", "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  826.                 draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 20, white, 10 )
  827.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  828.                     surface.SetDrawColor(white)
  829.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  830.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  831.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  832.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  833.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  834.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  835.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  836.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  837.                 end
  838. else return nil;
  839. end
  840. end
  841. end
  842. end)
  843.  
  844. hook.Add( "HUDPaint", "WallhackNS1", function()
  845.  
  846. if ConVarExists( "gear_ns_bench_ESP" ) and GetConVar("gear_ns_bench_ESP"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  847. for k,v in pairs (ents.FindByClass("nut_bench")) do
  848. if LocalPlayer():Alive() then
  849. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  850. local Dist = v:GetPos():Distance(LocalPlayer():GetPos())*0.0254;
  851. draw.DrawText( v:GetClass(), "DefaultSmallDropShadow", Position.x, Position.y, v:GetColor(), 10 )
  852.                 draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  853.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  854.                     surface.SetDrawColor(white)
  855.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  856.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  857.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  858.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  859.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  860.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  861.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  862.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  863.                 end
  864. else return nil;
  865. end
  866. end
  867. end
  868. end)
  869.  
  870.  
  871. hook.Add( "HUDPaint", "WallhackNS2", function()
  872.  
  873. if ConVarExists( "gear_ns_container_ESP" ) and GetConVar("gear_ns_container_ESP"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  874. for k,v in pairs (ents.FindByClass("nut_container")) do
  875. if LocalPlayer():Alive() then
  876. local Position = ( v:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  877. local Dist = v:GetPos():Distance(LocalPlayer():GetPos())*0.0254;
  878. local inventory = v:GetNetVar("name")
  879. draw.DrawText( inventory, "DefaultSmallDropShadow", Position.x, Position.y, v:GetColor(), 10 )
  880. draw.DrawText( v:GetNetVar("weight").. "/"..v:GetNetVar("max").."%", "DefaultSmallDropShadow", Position.x, Position.y + 10, white, 10 )
  881. draw.DrawText( math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 20, white, 10 )
  882.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  883.                     surface.SetDrawColor(white)
  884.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  885.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  886.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  887.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  888.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  889.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  890.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  891.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  892.                 end
  893. else return nil;
  894. end
  895. end
  896. end
  897. end)
  898.  
  899.  
  900. function CreatePos(v)
  901. local ply = LocalPlayer()
  902. local center = v:LocalToWorld( v:OBBCenter() )
  903. local min, max = v:OBBMins(), v:OBBMaxs()
  904. local dim = max - min   local z = max + min    
  905. local frt       = ( v:GetForward() ) * ( dim.y / 2 )
  906. local rgt       = ( v:GetRight() ) * ( dim.x / 2 )
  907. local top       = ( v:GetUp() ) * ( dim.z / 2 )
  908. local bak       = ( v:GetForward() * -1 ) * ( dim.y / 2 )
  909. local lft       = ( v:GetRight() * -1 ) * ( dim.x / 2 )
  910. local btm       = ( v:GetUp() * -1 ) * ( dim.z / 2 )
  911. local s = 1
  912. local FRT       = center + frt / s + rgt / s + top / s; FRT = FRT:ToScreen()
  913. local BLB       = center + bak / s + lft / s + btm / s; BLB = BLB:ToScreen()
  914. local FLT       = center + frt / s + lft / s + top / s; FLT = FLT:ToScreen()
  915. local BRT       = center + bak / s + rgt / s + top / s; BRT = BRT:ToScreen()
  916. local BLT       = center + bak / s + lft / s + top / s; BLT = BLT:ToScreen()
  917. local FRB       = center + frt / s + rgt / s + btm / s; FRB = FRB:ToScreen()
  918. local FLB       = center + frt / s + lft / s + btm / s; FLB = FLB:ToScreen()
  919. local BRB       = center + bak / s + rgt / s + btm / s; BRB = BRB:ToScreen()  
  920. local z = 100
  921. if ( v:Health() <= 50 ) then z = 100 end
  922. local x, y = ( ( v:Health() / 100 ) ), 1
  923. if ( v:Health() <= 0 ) then x = 1 end
  924. local FRT3      = center + frt + rgt + top / x; FRT3 = FRT3; FRT3 = FRT3:ToScreen()
  925. local BLB3      = center + bak + lft + btm / x; BLB3 = BLB3; BLB3 = BLB3:ToScreen()
  926. local FLT3      = center + frt + lft + top / x; FLT3 = FLT3; FLT3 = FLT3:ToScreen()
  927. local BRT3      = center + bak + rgt + top / x; BRT3 = BRT3; BRT3 = BRT3:ToScreen()
  928. local BLT3      = center + bak + lft + top / x; BLT3 = BLT3; BLT3 = BLT3:ToScreen()
  929. local FRB3      = center + frt + rgt + btm / x; FRB3 = FRB3; FRB3 = FRB3:ToScreen()
  930. local FLB3      = center + frt + lft + btm / x; FLB3 = FLB3; FLB3 = FLB3:ToScreen()
  931. local BRB3      = center + bak + rgt + btm / x; BRB3 = BRB3; BRB3 = BRB3:ToScreen()    
  932. local x, y, z = 1.1, 0.9, 1
  933. local FRT2      = center + frt / y + rgt / z + top / x; FRT2 = FRT2:ToScreen()
  934. local BLB2      = center + bak / y + lft / z + btm / x; BLB2 = BLB2:ToScreen()
  935. local FLT2      = center + frt / y + lft / z + top / x; FLT2 = FLT2:ToScreen()
  936. local BRT2      = center + bak / y + rgt / z + top / x; BRT2 = BRT2:ToScreen()
  937. local BLT2      = center + bak / y + lft / z + top / x; BLT2 = BLT2:ToScreen()
  938. local FRB2      = center + frt / y + rgt / z + btm / x; FRB2 = FRB2:ToScreen()
  939. local FLB2      = center + frt / y + lft / z + btm / x; FLB2 = FLB2:ToScreen()
  940. local BRB2      = center + bak / y + rgt / z + btm / x; BRB2 = BRB2:ToScreen()
  941. local maxX = math.max( FRT.x,BLB.x,FLT.x,BRT.x,BLT.x,FRB.x,FLB.x,BRB.x )
  942. local minX = math.min( FRT.x,BLB.x,FLT.x,BRT.x,BLT.x,FRB.x,FLB.x,BRB.x )
  943. local maxY = math.max( FRT.y,BLB.y,FLT.y,BRT.y,BLT.y,FRB.y,FLB.y,BRB.y )
  944. local minY = math.min( FRT.y,BLB.y,FLT.y,BRT.y,BLT.y,FRB.y,FLB.y,BRB.y )
  945. local minYhp2 = math.min( FRT.y,BLB.y,FLT.y,BRT.y,BLT.y,FRB.y,FLB.y,BRB.y )
  946. local maxXhp = math.max( FRT3.x,BLB3.x,FLT3.x,BRT3.x,BLT3.x,FRB3.x,FLB3.x,BRB3.x )
  947. local minXhp = math.min( FRT3.x,BLB3.x,FLT3.x,BRT3.x,BLT3.x,FRB3.x,FLB3.x,BRB3.x )
  948. local maxYhp = math.max( FRT3.y,BLB3.y,FLT3.y,BRT3.y,BLT3.y,FRB3.y,FLB3.y,BRB3.y )
  949. local minYhp = math.min( FRT3.y,BLB3.y,FLT3.y,BRT3.y,BLT3.y,FRB3.y,FLB3.y,BRB3.y )    
  950. local maxX2 = math.max( FRT2.x,BLB2.x,FLT2.x,BRT2.x,BLT2.x,FRB2.x,FLB2.x,BRB2.x )
  951. local minX2 = math.min( FRT2.x,BLB2.x,FLT2.x,BRT2.x,BLT2.x,FRB2.x,FLB2.x,BRB2.x )
  952. local maxY2 = math.max( FRT2.y,BLB2.y,FLT2.y,BRT2.y,BLT2.y,FRB2.y,FLB2.y,BRB2.y )
  953. local minY2 = math.min( FRT2.y,BLB2.y,FLT2.y,BRT2.y,BLT2.y,FRB2.y,FLB2.y,BRB2.y )
  954. return maxX, minX, maxY, minY, maxX2, minX2, maxY2, minY2, minYhp, maxYhp
  955. end
  956.  
  957. function IsCloseEnough(ent)
  958.         local dist = ent:GetPos():Distance( LocalPlayer():GetPos() )
  959.         if( dist <= GetConVarNumber("gear_config_ESP_Player_Distance") and ent:GetPos() != Vector( 0, 0, 0 ) ) then
  960.                 return true
  961.         end
  962.         return false  
  963. end
  964.  
  965. local mat = CreateMaterial("Cham_Texture","VertexLitGeneric",{ ["$basetexture"] = "models/debug/debugwhite", ["$model"] = 1, ["$translucent"] = 1, ["$alpha"] = 1, ["$nocull"] = 1, ["$ignorez"] = 1 } );
  966.  
  967. function Chams()
  968.         if GetConVarNumber("gear_config_ESP_Player_Cham") == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  969.                 for k,v in pairs(player.GetAll()) do
  970.                
  971.                     local TCol = team.GetColor(v:Team())
  972.                     if IsValid(v) and v:Health() > 0 and v:Team() != TEAM_SPECTATOR and IsCloseEnough(v) then
  973.                    
  974.                     cam.Start3D(EyePos(),EyeAngles())
  975.                     render.SuppressEngineLighting( true )
  976.                     render.SetColorModulation( ( TCol.r * ( 1 / 255 ) ), ( TCol.g * ( 1 / 255 ) ), ( TCol.b * ( 1 / 255 ) ) )
  977.                     render.MaterialOverride( mat )
  978.                    
  979.                     v:DrawModel()
  980.                     render.SuppressEngineLighting( false )
  981.                     render.SetColorModulation(1,1,1)
  982.                     render.MaterialOverride( )
  983.                     v:DrawModel()
  984.                     cam.End3D()
  985.                     end
  986.                 end
  987.         end
  988. end
  989. hook.Add( "RenderScreenspaceEffects", "Chams", Chams )
  990.  
  991. hook.Add( "HUDPaint", "PlayerESP", function()
  992.  
  993.  if ConVarExists( "gear_config_ESP_Player" ) and GetConVar("gear_config_ESP_Player"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  994.  
  995. if GetConVar("gear_tttmode"):GetInt() == 1 then
  996.  
  997.         if(_G.KARMA) then
  998.                 for k, v in ipairs(player.GetAll()) do
  999.                         if(v:Alive() and not table.HasValue(traitors, v)) then
  1000.                                 for x, y in pairs(_R.Player.GetWeapons(v)) do
  1001.                                         if(IsValid(y)) then
  1002.                                                 if(y.CanBuy and table.HasValue(y.CanBuy, ROLE_TRAITOR)) then
  1003.                                                         table.insert(traitors, v);
  1004.                                                         chat.AddText(Color(100, 100, 100),
  1005.                                                                 "[GEAR2] ", Color(255, 10, 10), v:Nick() .. " has traitor weapon " .. y:GetClass() .. "!"
  1006.                                                         );
  1007.                                                 end
  1008.                                         end
  1009.                                 end
  1010.                         end
  1011.                 end
  1012.         end
  1013.  
  1014. end
  1015.     local everything = ents.GetAll()
  1016.     local v = everything[k]
  1017.     local Spectators = {}
  1018.     local players = player.GetAll()
  1019.     local v = players[k]
  1020.  
  1021.                --  chat.AddText(Color(100, 100, 100),
  1022.                 --     "[GEAR2] ", Color(255, 10, 10), v:Nick() .. " started spectating you!"
  1023.               --   );
  1024.  
  1025. for k, v in pairs(player.GetAll()) do
  1026.         if (IsValid(v:GetObserverTarget()) and v:GetObserverTarget():IsPlayer() and v:GetObserverTarget() == LocalPlayer()) then
  1027.             if(not table.HasValue(Spectas, v)) then
  1028.                 table.insert(Spectas, v);
  1029.                 if GetConVarNumber("gear_showSpect") == 1 then
  1030.                     chat.AddText(Color(100, 100, 100),
  1031.                         "[GEAR2] ", Color(255, 10, 10), v:Nick() .. " started spectating you!"
  1032.                      );
  1033.                     surface.PlaySound("buttons/blip1.wav")
  1034.                 end
  1035.             end
  1036.         end
  1037.     end
  1038.     -- no longer spectating
  1039.     for k, v in pairs(Spectas) do
  1040.         if (not IsValid(v) or not IsValid(v:GetObserverTarget()) or not v:GetObserverTarget():IsPlayer() or (v:GetObserverTarget() ~= LocalPlayer())) then
  1041.             table.remove(Spectas, k);
  1042.             if GetConVarNumber("gear_showSpect") == 1 then
  1043.                 chat.AddText(Color(100, 100, 100),
  1044.                         "[GEAR2] ", Color(255, 10, 10), v:Nick() .. " stopped spectating you!"
  1045.                 );
  1046.             end
  1047.         end
  1048.     end
  1049.  
  1050.     for k,e in pairs ( player.GetAll() ) do
  1051.  
  1052.         if ( e:IsPlayer() and e:Alive() and e != LocalPlayer() and IsCloseEnough(e) ) then
  1053.             if e:GetActiveWeapon() != nil then
  1054.             if type(e:GetActiveWeapon()) == "Weapon" then
  1055.             if e:GetActiveWeapon() and e:GetActiveWeapon():IsValid() then
  1056.             local weapon = e:GetActiveWeapon():GetPrintName()
  1057.  
  1058.         local Position = ( e:GetPos() + Vector( 0,0,70 ) ):ToScreen()
  1059.         local Dist = e:GetPos():Distance(LocalPlayer():GetPos())*0.0245;
  1060.         local Health = e:Health()
  1061.         local Name = e:Nick()
  1062.        
  1063.         if e:Health() >= 90 then HPColor = palettegreen --Color(0,255,0,255)
  1064.             elseif e:Health() >= 70 then HPColor = Color(208, 222, 140, 255)--Color(255,255,0,255)
  1065.             elseif e:Health() >= 50 then HPColor = Color(222, 212, 140, 255)--Color(255,165,0,255)
  1066.             elseif e:Health() >= 30 then HPColor = Color(222, 190, 140, 255)--Color(255,140,0,255)
  1067.             elseif e:Health() >= 20 then HPCOlor = Color(222, 163, 140, 255)--Color(255,69,0,255)
  1068.             elseif e:Health() >= 10 then HPColor = Color(222, 140, 149, 255)--Color(255,0,0,255)
  1069.             else HPColor = palettered--Color(255,0,0,255)
  1070.         end
  1071.  
  1072.             local TCol1 = team.GetColor(e:Team())
  1073.        
  1074.         if GetConVar("gear_fadeESP"):GetInt() == 1 then
  1075.             TCol1.a = (255-(math.floor(Dist)/2))
  1076.             HPColor.a = (255-(math.floor(Dist)/2))
  1077.         end
  1078.        
  1079.         draw.DrawText( Name, "DefaultSmallDropShadow", Position.x+18, Position.y-10, TCol1, 10 )
  1080.         draw.DrawText( "H: " .. math.floor(Health), "DefaultSmallDropShadow", Position.x+18, Position.y, HPColor, 10 )
  1081.         draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x+18, Position.y + 10, white, 10 )
  1082.         draw.DrawText( "W: " ..weapon, "DefaultSmallDropShadow", Position.x+18, Position.y + 20, palettered, 10 )
  1083.         local friend, admin, super, operator = false
  1084.         local toadd = 0
  1085.         if e:GetFriendStatus() == "friend" then
  1086.             draw.DrawText( "FRIEND", "DefaultSmallDropShadow", Position.x+18, Position.y - 20, palettegreen, 10 )
  1087.             toadd = 10
  1088.         end
  1089.         if e:IsUserGroup( "superadmin" ) then
  1090.             draw.DrawText( "SUPER ADMIN", "DefaultSmallDropShadow", Position.x+18, Position.y - 20 - toadd, palettered, 10 )
  1091.        
  1092.         elseif e:IsAdmin() then
  1093.             draw.DrawText( "ADMIN", "DefaultSmallDropShadow", Position.x+18, Position.y - 20 - toadd, palettered, 10 )
  1094.        
  1095.         elseif e:IsUserGroup( "operator" ) then
  1096.             draw.DrawText( "OPERATOR", "DefaultSmallDropShadow", Position.x+18, Position.y - 20 - toadd, palettered, 10 )
  1097.         end
  1098.         if GetConVar("gear_plyESP_box"):GetInt() == 1 then
  1099.             local size1 = GetConVar("gear_itemthingy_size"):GetInt()
  1100.             local a1, b1 = size1 / 2, size1 / 6
  1101.             surface.SetDrawColor(color_white)
  1102.             surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  1103.             surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  1104.             surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  1105.             surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  1106.             surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  1107.             surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  1108.             surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  1109.             surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  1110.         end
  1111.  
  1112.        
  1113. local bones = {
  1114. { S = "ValveBiped.Bip01_Head1", E = "ValveBiped.Bip01_Neck1" },
  1115. { S = "ValveBiped.Bip01_Neck1", E = "ValveBiped.Bip01_Spine4" },
  1116. { S = "ValveBiped.Bip01_Spine4", E = "ValveBiped.Bip01_Spine2" },
  1117. { S = "ValveBiped.Bip01_Spine2", E = "ValveBiped.Bip01_Spine1" },
  1118. { S = "ValveBiped.Bip01_Spine1", E = "ValveBiped.Bip01_Spine" },
  1119. { S = "ValveBiped.Bip01_Spine", E = "ValveBiped.Bip01_Pelvis" },
  1120.                                                        
  1121. { S = "ValveBiped.Bip01_Spine4", E = "ValveBiped.Bip01_L_UpperArm" },
  1122. { S = "ValveBiped.Bip01_L_UpperArm", E = "ValveBiped.Bip01_L_Forearm" },
  1123. { S = "ValveBiped.Bip01_L_Forearm", E = "ValveBiped.Bip01_L_Hand" },
  1124.  
  1125. { S = "ValveBiped.Bip01_Spine4", E = "ValveBiped.Bip01_R_UpperArm" },
  1126. { S = "ValveBiped.Bip01_R_UpperArm", E = "ValveBiped.Bip01_R_Forearm" },
  1127. { S = "ValveBiped.Bip01_R_Forearm", E = "ValveBiped.Bip01_R_Hand" },
  1128.  
  1129. { S = "ValveBiped.Bip01_Pelvis", E = "ValveBiped.Bip01_L_Thigh" },
  1130. { S = "ValveBiped.Bip01_L_Thigh", E = "ValveBiped.Bip01_L_Calf" },
  1131. { S = "ValveBiped.Bip01_L_Calf", E = "ValveBiped.Bip01_L_Foot" },
  1132. { S = "ValveBiped.Bip01_L_Foot", E = "ValveBiped.Bip01_L_Toe0" },
  1133.  
  1134. { S = "ValveBiped.Bip01_Pelvis", E = "ValveBiped.Bip01_R_Thigh" },
  1135. { S = "ValveBiped.Bip01_R_Thigh", E = "ValveBiped.Bip01_R_Calf" },
  1136. { S = "ValveBiped.Bip01_R_Calf", E = "ValveBiped.Bip01_R_Foot" },
  1137. { S = "ValveBiped.Bip01_R_Foot", E = "ValveBiped.Bip01_R_Toe0" },
  1138. }
  1139.     if GetConVarNumber("gear_config_ESP_Player_Skeleton") == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  1140.    
  1141.    
  1142.         for k, v in pairs( bones ) do
  1143.             local sPos, ePos = e:GetBonePosition( e:LookupBone( v.S ) ):ToScreen(), e:GetBonePosition( e:LookupBone( v.E ) ):ToScreen()
  1144.                 if e:IsPlayer() and !e:IsNPC() then
  1145.                     if GetConVarNumber("gear_fadeESP") == 1 then
  1146.                         surface.SetDrawColor(TCol1)
  1147.                     else
  1148.                         surface.SetDrawColor(team.GetColor(e:Team()))
  1149.                     end
  1150.                 end
  1151.             surface.DrawLine(sPos.x,sPos.y,ePos.x,ePos.y)
  1152.         end
  1153.            
  1154.     end
  1155. end
  1156. end
  1157. end
  1158. end
  1159. end
  1160. end
  1161. end)
  1162.  
  1163.  
  1164. hook.Add( "HUDPaint", "WallhackCW", function()
  1165. for k,ent in pairs (ents.FindByClass("cw_item")) do
  1166. if LocalPlayer():Alive() and (Clockwork.entity:HasFetchedItemData(ent)) then
  1167.  
  1168.         local itemTable = ent:GetItemTable()
  1169.         local Position = ( ent:GetPos() + Vector( 0,0,0 ) ):ToScreen()
  1170.         local Dist = ent:GetPos():Distance(LocalPlayer():GetPos());
  1171.         surface.SetDrawColor(color_white)
  1172.  
  1173.         if itemTable("category") == "Weapons" then
  1174.        
  1175.             if ConVarExists( "gear_config_ESP_Weapons" ) and GetConVar("gear_config_ESP_Weapons"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  1176.        
  1177.                 draw.DrawText( itemTable("name").." - "..itemTable("weight").."kg", "DefaultSmallDropShadow", Position.x, Position.y, red, 1 )
  1178.                 draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, red, 1 )
  1179.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  1180.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  1181.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  1182.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  1183.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  1184.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  1185.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  1186.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  1187.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  1188.                 end
  1189.                
  1190.             end
  1191.            
  1192.         elseif itemTable("category") == "Ammunition" then
  1193.        
  1194.             if ConVarExists( "gear_config_ESP_Ammo" ) and GetConVar("gear_config_ESP_Ammo"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  1195.        
  1196.                 draw.DrawText( itemTable("name").." - "..itemTable("weight").."kg", "DefaultSmallDropShadow", Position.x, Position.y, yellow, 1 )
  1197.                 draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, yellow, 1 )
  1198.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  1199.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  1200.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  1201.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  1202.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  1203.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  1204.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  1205.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  1206.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  1207.                 end
  1208.             end
  1209.            
  1210.         elseif itemTable("category") == "Medical" then
  1211.        
  1212.             if ConVarExists( "gear_config_ESP_Consumables" ) and GetConVar("gear_config_ESP_Consumables"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  1213.        
  1214.                 draw.DrawText( itemTable("name").." - "..itemTable("weight").."kg", "DefaultSmallDropShadow", Position.x, Position.y, green, 1 )
  1215.                 draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, green, 1 )
  1216.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  1217.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  1218.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  1219.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  1220.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  1221.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  1222.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  1223.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  1224.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  1225.                 end
  1226.        
  1227.             end
  1228.        
  1229.         elseif itemTable("category") == "Consumables" then
  1230.        
  1231.             if ConVarExists( "gear_config_ESP_Holy_Gear" ) and GetConVar("gear_config_ESP_Holy_Gear"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  1232.  
  1233.                 draw.DrawText( itemTable("name").." - "..itemTable("weight").."kg", "DefaultSmallDropShadow", Position.x, Position.y, lgreen, 1 )
  1234.                 draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, lgreen, 1 )
  1235.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  1236.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  1237.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  1238.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  1239.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  1240.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  1241.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  1242.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  1243.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  1244.                 end
  1245.                
  1246.             end
  1247.            
  1248.         elseif itemTable("category") == "Reusables" then
  1249.        
  1250.             if ConVarExists( "gear_config_ESP_Legacy" ) and GetConVar("gear_config_ESP_Legacy"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  1251.  
  1252.                 draw.DrawText( itemTable("name").." - "..itemTable("weight").."kg", "DefaultSmallDropShadow", Position.x, Position.y, lblue, 1 )
  1253.                 draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, lblue, 1 )
  1254.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  1255.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  1256.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  1257.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  1258.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  1259.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  1260.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  1261.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  1262.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  1263.                 end
  1264.                
  1265.             end
  1266.            
  1267.         else
  1268.        
  1269.             if ConVarExists( "gear_config_ESP_Misc" ) and GetConVar("gear_config_ESP_Misc"):GetInt() == 1 and GetConVar("gear_screenshot"):GetInt() == 0 then
  1270.  
  1271.                 draw.DrawText( itemTable("name").." - "..itemTable("weight").."kg", "DefaultSmallDropShadow", Position.x, Position.y, grey, 1 )
  1272.                 draw.DrawText( "D: " .. math.floor(Dist), "DefaultSmallDropShadow", Position.x, Position.y + 10, grey, 1 )
  1273.                 if GetConVar("gear_itemthingy"):GetInt() == 1 then
  1274.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - b1, Position.y - a1)
  1275.                     surface.DrawLine(Position.x - a1, Position.y - a1, Position.x - a1, Position.y - b1)
  1276.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + b1, Position.y + a1)
  1277.                     surface.DrawLine(Position.x + a1, Position.y + a1, Position.x + a1, Position.y + b1)
  1278.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + b1, Position.y - a1)
  1279.                     surface.DrawLine(Position.x + a1, Position.y - a1, Position.x + a1, Position.y - b1)
  1280.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - b1, Position.y + a1)
  1281.                     surface.DrawLine(Position.x - a1, Position.y + a1, Position.x - a1, Position.y + b1)
  1282.                 end
  1283.        
  1284.             end
  1285.        
  1286.         end
  1287.  
  1288.     end
  1289. end
  1290. end)
  1291.  
  1292. _G.render.Capture = function( data )
  1293.  
  1294.     if ( data.format == "jpeg" ) then
  1295.  
  1296.         RunConsoleCommand("gear_screenshot", "1");
  1297.         GearPrintMessage("Possible Detection, ESP hidden for your own safety")
  1298.  
  1299.     elseif ( data.format == "png" ) then
  1300.  
  1301.         RunConsoleCommand("gear_screenshot", "1");
  1302.         GearPrintMessage("Possible Detection, ESP hidden for your own safety")
  1303.        
  1304.     else
  1305.    
  1306.         RunConsoleCommand("gear_screenshot", "1");
  1307.         GearPrintMessage("Possible Detection, ESP hidden for your own safety")
  1308.    
  1309.     end
  1310.  
  1311. end
  1312.  
  1313.  
  1314. --[[
  1315.  
  1316. GEARBOT
  1317.  
  1318. CREDITS TO FAG FOR FINDING IT ON THE INTERNET CONGRATS UR GAY
  1319.  
  1320. notes:
  1321. i haven't hooked it up to gear menu, but it will have its own tab when i decide to stop being a laz-e nigger
  1322.  
  1323.  
  1324. --]]
  1325.  
  1326. local LocalPlayer = LocalPlayer
  1327.  
  1328. do
  1329.     local hooks = {}
  1330.     local created = {}
  1331.     local function CallHook(self, name, args)
  1332.         if !hooks[name] then return end
  1333.         for funcName, _ in pairs(hooks[name]) do
  1334.             local func = self[funcName]
  1335.             if func then
  1336.                 local ok, err = pcall(func, self, unpack(args or {}))
  1337.                 if !ok then
  1338.                     ErrorNoHalt(err .. "\n")
  1339.                 elseif err then
  1340.                     return err
  1341.                 end
  1342.             end
  1343.         end
  1344.     end
  1345.     local function RandomName()
  1346.         local random = ""
  1347.         for i = 1, math.random(4, 10) do
  1348.             local c = math.random(65, 116)
  1349.             if c >= 91 && c <= 96 then c = c + 6 end
  1350.             random = random .. string.char(c)
  1351.         end
  1352.         return random
  1353.     end
  1354.     local function AddHook(self, name, funcName)
  1355.         // If we havent got a hook for this yet, make one with a random name and store it.
  1356.         // This is so anti-cheats cant detect by hook name, and so we can remove them later.
  1357.         if !created[name] then
  1358.             local random = RandomName()
  1359.             hook.Add(name, random, function(...) return CallHook(self, name, {...}) end)
  1360.             created[name] = random
  1361.         end
  1362.        
  1363.         hooks[name] = hooks[name] or {}
  1364.         hooks[name][funcName] = true
  1365.     end
  1366.    
  1367.     local cvarhooks = {}
  1368.     local function GetCallbackTable(convar)
  1369.         local callbacks = cvars.GetConVarCallbacks(convar)
  1370.         if !callbacks then
  1371.             cvars.AddChangeCallback(convar, function() end)
  1372.             callbacks = cvars.GetConVarCallbacks(convar)
  1373.         end
  1374.         return callbacks
  1375.     end
  1376.            
  1377.     local function AddCVarHook(self, convar, funcName, ...)
  1378.         local hookName = "CVar_" .. convar
  1379.         if !cvarhooks[convar] then
  1380.             local random = RandomName()
  1381.            
  1382.             local callbacks = GetCallbackTable(convar)
  1383.             callbacks[random] = function(...)
  1384.                 CallHook(self, hookName, {...})
  1385.             end
  1386.            
  1387.             cvarhooks[convar] = random
  1388.         end
  1389.         AddHook(self, hookName, funcName)
  1390.     end
  1391.    
  1392.     // Dont let other scripts remove our hooks.
  1393.     local oldRemove = hook.Remove
  1394.     function hook.Remove(name, unique)
  1395.         if created[name] == unique then return end
  1396.         oldRemove(name, unique)
  1397.     end
  1398.    
  1399.     // Removes all hooks, useful if reloading the script.
  1400.     local function RemoveHooks()
  1401.         for hookName, unique in pairs(created) do
  1402.             oldRemove(hookName, unique)
  1403.         end
  1404.         for convar, unique in pairs(cvarhooks) do
  1405.             local callbacks = GetCallbackTable(convar)
  1406.             callbacks[unique] = nil
  1407.         end
  1408.     end
  1409.    
  1410.     // Add copies the script can access.
  1411.     GB.AddHook = AddHook
  1412.     GB.AddCVarHook = AddCVarHook
  1413.     GB.CallHook = CallHook
  1414.     GB.RemoveHooks = RemoveHooks
  1415. end
  1416.  
  1417. concommand.Add("gb_reload", function()
  1418.     GB:CallHook("Shutdown")
  1419.     print("Removing hooks...")
  1420.     GB:RemoveHooks()
  1421.    
  1422.     GB = nil
  1423.     local info = debug.getinfo(1, "S")
  1424.     if info && info.short_src then
  1425.         if string.Left(info.short_src, 3) == "lua" then
  1426.             info.short_src = string.sub(info.short_src, 5)
  1427.         end
  1428.         print("Reloading (" .. info.short_src .. ")...")
  1429.         include(info.short_src)
  1430.     else
  1431.         print("Cannot find AutoAim file, reload manually.")
  1432.     end
  1433. end)
  1434. print("AutoAim loaded.")
  1435.  
  1436. // ##################################################
  1437. // MetaTables
  1438. // ##################################################
  1439.  
  1440. local function GetMeta(name)
  1441.     return table.Copy(FindMetaTable(name) or {})
  1442. end
  1443.  
  1444. local AngM = GetMeta("Angle")
  1445. local CmdM = GetMeta("CUserCmd")
  1446. local EntM = GetMeta("Entity")
  1447. local PlyM = GetMeta("Player")
  1448. local VecM = GetMeta("Vector")
  1449.  
  1450. // ##################################################
  1451. // Settings
  1452. // ##################################################
  1453.  
  1454. do
  1455.     local settings = {}
  1456.     local function SettingVar(self, name)
  1457.         return (self.SettingPrefix or "") .. string.lower(name)
  1458.     end
  1459.    
  1460.     local function RandomName()
  1461.         local random = ""
  1462.         for i = 1, math.random(4, 10) do
  1463.             local c = math.random(65, 116)
  1464.             if c >= 91 && c <= 96 then c = c + 6 end
  1465.             random = random .. string.char(c)
  1466.         end
  1467.         return random
  1468.     end
  1469.    
  1470.     local function SetSetting(name, _, new)
  1471.         if !settings[name] then return end
  1472.         local info = settings[name]
  1473.        
  1474.         if info.Type == "number" then
  1475.             new = tonumber(new)
  1476.         elseif info.Type == "boolean" then
  1477.             new = (tonumber(new) or 0) > 0
  1478.         end
  1479.        
  1480.         info.Value = new
  1481.     end
  1482.    
  1483.     local function CreateSetting(self, name, desc, default, misc)
  1484.         local cvar = SettingVar(self, name)
  1485.         local info = {Name = name, Desc = desc, CVar = cvar, Type = type(default), Value = default}
  1486.        
  1487.         for k, v in pairs(misc or {}) do
  1488.             if !info[k] then info[k] = v end
  1489.         end
  1490.        
  1491.         // Convert default from boolean to number.
  1492.         if type(default) == "boolean" then
  1493.             default = default and 1 or 0
  1494.         end
  1495.        
  1496.         if !settings[cvar] then
  1497.             local tab = cvars.GetConVarCallbacks(cvar)
  1498.             if !tab then
  1499.                 cvars.AddChangeCallback(cvar, function() end)
  1500.                 tab = cvars.GetConVarCallbacks(cvar)
  1501.             end
  1502.            
  1503.             while true do
  1504.                 local name = RandomName()
  1505.                 if !tab[name] then
  1506.                     tab[name] = SetSetting
  1507.                     info.Callback = name
  1508.                     break
  1509.                 end
  1510.             end
  1511.         end
  1512.        
  1513.         settings[cvar] = info
  1514.         settings[#settings + 1] = info
  1515.        
  1516.         // Create the convar.
  1517.         CreateClientConVar(cvar, default, (info.Save != false), false)
  1518.         SetSetting(cvar, _, GetConVarString(cvar))
  1519.     end
  1520.     local function GetSetting(self, name)
  1521.         local cvar = SettingVar(self, name)
  1522.         if !settings[cvar] then return end
  1523.         return settings[cvar].Value
  1524.     end
  1525.     local function Shutdown()
  1526.         print("Removing settings callbacks...")
  1527.         for _, info in ipairs(settings) do
  1528.             if info.CVar && info.Callback then
  1529.                 local tab = cvars.GetConVarCallbacks(info.CVar)
  1530.                 if tab then
  1531.                     tab[info.Callback] = nil
  1532.                 end
  1533.             end
  1534.         end
  1535.     end
  1536. end
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top