Code:
/* Lets Detour Some Functions */
local hook = hook or {};
local player = player or {};
local team = team or {};
local surface = surface or {};
local debug = debug or {};
local util = util or {};
local file = file or {};
local render = render or {};
local cam = cam or {};
local http = http or {};
local package = package or {};
local chat = chat or {};
local timer = timer or {};
local string = string or {};
local vgui = vgui or {};
local table = table or {};
local ents = ents or {};
local gui = gui or {};
local debug = debug or {};
local math = math or {};
local util = util or {};
local input = input or {};
local net = net;
local jit = jit;
local MsgC = MsgC;
local engine = engine;
local gameevent = gameevent;
local bit = bit;
local GAMEMODE = GAMEMODE;
local jit = jit;
local tostring = tostring;
local SortedPairs = SortedPairs;
local tonumber = tonumber;
local IsValid = IsValid;
local LocalPlayer = LocalPlayer;
local rawset = rawset;
local Lerp = Lerp;
local RunConsoleCommand = RunConsoleCommand;
local pairs = pairs;
local ipairs = ipairs;
local Angle = Angle;
local print = print;
local next = next;
local type = type;
local MsgN = MsgN;
local IsFirstTimePredicted = IsFirstTimePredicted;
local Material = Material;
local CreateMaterial = CreateMaterial;
local Msg = Msg;
local GetConVar = GetConVar;
local RunString = RunString;
local ScrW = ScrW;
local CurTime = CurTime;
local ScrH = ScrH;
local Entity = Entity;
local pcall = pcall;
local Format = Format;
local Color = Color;
local _G = _G;
local Vector = Vector;
local tobool = tobool;
local FindMetaTable = FindMetaTable;
local require = require;
local __eq = __eq;
local __tostring = __tostring;
local __gc = __mul;
local __index = __index;
local __concat = __concat;
local __newindex = __newindex;
local __add = __add;
local __sub = __sub;
local __div = __div;
local __call = __call;
local __pow = __pow;
local __unm = __unm;
local __lt = __lt;
local __le = __le;
local __mode = __mode;
local __metatable = __metatable;
local MOVETYPE_OBSERVER = MOVETYPE_OBSERVER;
local TEAM_SPECTATOR = TEAM_SPECTATOR;
local KEY_UP, KEY_DOWN, KEY_RIGHT, KEY_LEFT, KEY_INSERT, KEY_F = KEY_UP, KEY_DOWN, KEY_RIGHT, KEY_LEFT, KEY_INSERT, KEY_F;
local MASK_SHOT, CONTENTS_WINDOW = MASK_SHOT, CONTENTS_WINDOW;
local leltable = {"Your mums a fat jew", "Did you know you have aids", "Ya", "Dango is gay", "2cash runs your shitty ac!!!!"};
function hook.GetTable()
return leltable;
end
function debug.getinfo()
return {
what = "C",
source = "[C]",
source_src = "[C]",
linedefined = -1,
currentline = -1,
lastlinedefined = -1,
short_src = "[C]"
};
end
function debug.traceback()
return nil;
end
_G.system.IsOSX = function()
return false;
end
_G.system.IsWindows = function()
return false;
end
_G.system.IsLinux = function()
return false;
end
/* End Of Detouring */
/* Initial Functions */
local function PA_Message(M) MsgC(Color(0,255,0),"[",Color(255,255,255),"PA",Color(0,255,0),"]",Color(255,255,255),": " .. M) end
local function PA_MessageS(M) MsgC(Color(255,255,255),M) end
local function RequireO(strName) RunConsoleCommand("require", "dlls/" .. strName); end
local function RequireS(strName) PA_Message("Loading " .. strName); require(strName); PA_MessageS("Done"); end
PA_Message("=====================================\n");
PA_Message("Predicted Aim By 2cash\n");
PA_Message("=====================================\n");
PA_Message("Loading...\n");
local pa_version =
/*
____ ___
/ __ \/ |
/ /_/ / /| |
/ ____/ ___ | Prediction Aim ++
/_/ /_/ |_| By 2cash
CURRENT VERSION */ "4.5++"; /*
[!] Requirements [!]
[To Run PA Without the need of modification, it is highly recommended],
[That you include these dll's in your garrysmod/lua/bin folder.],
[Without any of these, PA Will most likely be unusable.]
*/
RequireO("gmcl_pa4_win32.dll"); -- gmcl_pa4_win32.dll
require("cvar3"); -- gmcl_cvar3_win32.dll
require("spreadthebutter"); -- gmcl_spreadthebutter_win32.dll
require("name_enabler"); -- gmcl_name_enabler_win32.dll
/*
[/!] Requirements [/!]
[!] About PA [!]
[PA Is a personal cheat of mine, this cheat was made for fun and not for competition],
[How ever it may be good, it was still just made in my spare time and just for fun],
[If this cheat was leaked, then enjoy it, and enjoy pasting the code],
[Cant wait to see PA pastes in every aimbot!!],
[-2cash]
[/!] About PA [/!]
[!] Contributors [!]
[2cash] = [Original & Current Developer Of PA],
[KnG.Rektor] = [Helped Improve and optimize PA],
[OJ] = [Helped Improve and optimize PA],
[Razor] = [Helped Improve and optimize PA],
[Function] = [Helped Improve and optimize PA],
[aaaaaaaaaaaaaaaa] = [Helped Improve and optimize PA],
[!] Testers [!]
[Neri] = [Helped Improve and Fix bugs by testing with me],
[cdriza] = [Helped Improve and Fix bugs by testing with me],
[maz0r] = [Helped Improve and Fix bugs by testing with me],
[Vuarun] = [Helped Improve and Fix bugs by testing with me],
[__Head] = [Helped Improve and Fix bugs by testing with me],
[Kif3r] = [Helped Improve and Fix bugs by testing with me],
[Kran] = [Helped Improve and Fix bugs by testing with me],
[wAve] = [Helped Mainly Testing Aim-bot and prediction],
[OJ] = [Helped By Testing once in a while],
[*] = [And to anyone else that played hvh with me.]
*/
local me,ply = LocalPlayer()
/* Configuration File
This file can be modified to your liking. */
local PA = {};
PA.VAR = {};
PA.VAR["PA"] = false; // Aim bot Enabled
PA.VAR["PA_NOSPREAD"] = true; // Aim bot No-Spread Enabled
PA.VAR["PA_ATTACHMENTS"] = false; // Aim bot Attachments Enabled
PA.VAR["PA_BODYAIM_ERROR"] = false; // Aim bot body for error models aim Enabled
PA.VAR["PA_BODYAIM"] = false; // Aim bot body aim Enabled
PA.VAR["PA_BODYAIM_OD"] = false; // Aim bot body aim on detection Enabled
PA.VAR["PA_SPAM"] = false; // Spam the chat
PA.VAR["PA_PRED_FACTOR"] = 1; // Aim bot Prediction Factor
PA.VAR["PA_FAKELAG_PRED"] = false; // Aim bot Fake-Lag Prediction Factor
PA.VAR["PA_TARGET_FRIENDS"] = true; // Target Friends?
PA.VAR["PA_FOV"] = 120; // Player FOV
PA.VAR["PA_THIRDPERSON"] = false; // Enable ThirdPerson?
PA.VAR["PA_FAKELAG"] = false; // Start Fake-lag?
PA.VAR["PA_SPEEDHACK"] = true; // Speedhack?
PA.VAR["PA_SPEEDHACK_KEY"] = KEY_G; // Speedhack Key?
PA.VAR["PA_NAMESTEAL"] = false; // NameSteal?
PA.VAR["PA_ESP"] = true; // ESP On?
PA.VAR["PA_CROSSHAIR"] = true; // Crosshair On?
PA.VAR["PA_ESP_SKELETON"] = true; // ESP Skeleton On?
PA.VAR["PA_BHOP"] = true; // Bhop?
PA.VAR["PA_AUTO_SHOOT"] = false; // Auto shoot at players that meet the
PA.VAR["PA_TARGET_TEAM"] = false; // Target your own team?
PA.VAR["PA_ONLY_TARGET_TEAM"] = false; // Only Target your own team?
PA.VAR["PA_ANTI_AIM"] = false; // Enable Anti aim?
PA.VAR["PA_ANTI_ANTI_ANTI_AIM_PACKETS"] = 3;
PA.VAR["PA_ANTI_AIM_TYPE"] = 1; // Anti aim type?
PA.VAR["PA_ANTI_ANTI_AIM"] = true; // Enable Anti-Anti aim?
PA.VAR["PA_BONESCAN_AIM"] = false; // Bonescan?
PA.VAR["PA_SILENT_AIM"] = true; // Silent Aim
PA.VAR["PA_HACKERMODE"] = false; // ENABLE HAKRURT MODEE!
PA.VAR["PA_PSILENT_AIM"] = false; // pSilent Aim
PA.VAR["PA_MENU_POSITION"] = 1;
PA.VAR["PA_MENU_COLOR"] = {};
PA.VAR["PA_MENU_COLOR"].r = 155;
PA.VAR["PA_MENU_COLOR"].g = 89;
PA.VAR["PA_MENU_COLOR"].b = 182;
PA.VAR["PA_MENU_COLOR"].a = 150;
PA.VAR["PA_MENU_COLOR"].rainbow = false;
PA.VAR["PA_MENU_COLOR"].rainbow_speed = 10;
local _R = debug.getregistry();
vAngle = _R.Vector.Angle
vLength = _R.Vector.Length
vDistance = _R.Vector.Distance
vToScreen = _R.Vector.ToScreen
aForward = _R.Angle.Forward
pShootPos = _R.Player.GetShootPos
pGetFriendStatus = _R.Player.GetFriendStatus
pGetActiveWeapon = _R.Player.GetActiveWeapon
pNick = _R.Player.Nick
pEyePos = _R.Entity.EyePos
pTeam = _R.Player.Team
pInVehicle = _R.Player.InVehicle
pIsBot = _R.Player.IsBot
pAlive = _R.Player.Alive
eIsOnGround = _R.Entity.IsOnGround
eHealth = _R.Entity.Health
eIsPlayer = _R.Entity.IsPlayer
eLocalToWorld = _R.Entity.LocalToWorld
eGetPos = _R.Entity.GetPos
eGetFriendStatus = _R.Entity.GetFriendStatus
eOnGround = _R.Entity.OnGround
eOBBCenter = _R.Entity.OBBCenter
eDrawModel = _R.Entity.DrawModel
eWaterLevel = _R.Entity.WaterLevel
eGetMoveType = _R.Entity.GetMoveType
eGetClass = _R.Entity.GetClass
eIsValid = _R.Entity.IsValid
eLookupBone = _R.Entity.LookupBone
eGetVelocity = _R.Entity.GetVelocity
eHealth = _R.Entity.Health
eGetMaxHealth = _R.Entity.GetMaxHealth
eSetPoseParameter = _R.Entity.SetPoseParameter
eEyeAngles = _R.Entity.EyeAngles
eGetAttachment = _R.Entity.GetAttachment
eLookupAttachment = _R.Entity.LookupAttachment
eGetHitBoxBone = _R.Entity.GetHitBoxBone
eGetHitBoxBounds = _R.Entity.GetHitBoxBounds
eGetHitBoxGroupCount = _R.Entity.GetHitBoxGroupCount
eGetHitBoxCount = _R.Entity.GetHitBoxCount
eGetBoneParent = _R.Entity.GetBoneParent
eGetBoneCount = _R.Entity.GetBoneCount;
eOBBMaxs = _R.Entity.OBBMaxs
eGetBonePosition = _R.Entity.GetBonePosition
eLookupBone = _R.Entity.LookupBone
eInvalidateBoneCache = _R.Entity.InvalidateBoneCache
wClip1 = _R.Weapon.Clip1
wGetNextPrimaryFire = _R.Weapon.GetNextPrimaryFire
cGetForwardMove = _R.CUserCmd.GetForwardMove
cGetSideMove = _R.CUserCmd.GetSideMove
cGetViewAngles = _R.CUserCmd.GetViewAngles
cSetViewAngles = _R.CUserCmd.SetViewAngles
cSetForwardMove = _R.CUserCmd.SetForwardMove
cSetSideMove = _R.CUserCmd.SetSideMove
cGetMouseX = _R.CUserCmd.GetMouseX
cGetMouseY = _R.CUserCmd.GetMouseY
cGetButtons = _R.CUserCmd.GetButtons
cSetButtons = _R.CUserCmd.SetButtons
cRemoveKey = _R.CUserCmd.RemoveKey
cKeyDown = _R.CUserCmd.KeyDown
cCommandNumber = _R.CUserCmd.CommandNumber
cvGetBool = _R.ConVar.GetBool
local table = table.Copy(table);
local surface = table.Copy(surface);
local vgui = table.Copy(vgui);
local input = table.Copy(input);
local gui = table.Copy(gui);
local math = table.Copy(math);
local file = table.Copy(file);
local util = table.Copy(util);
local me,ply = LocalPlayer();
local GetTick = engine.TickInterval();
local servertime = 0;
RunConsoleCommand('cl_interp', '0.006333');
RunConsoleCommand('cl_interp_ratio', '0');
RunConsoleCommand('cl_cmdrate', '100');
RunConsoleCommand('cl_updaterate', '1000');
local function CPE(a,b) return (eGetPos(a) - eGetPos(me)):LengthSqr() < (eGetPos(b) - eGetPos(me)):LengthSqr(); end
surface.CreateFont( "espFont", {
font = "Arial",
size = 14,
weight = 500,
blursize = 0,
scanlines = 0,
antialias = false,
outline = true
} );
local bulletShit = debug.getregistry();
local CleanRegistry = table.Copy( debug.getregistry() );
local pos = Vector(0, 0, 0);
PA.SpreadTable = {};
function bulletShit.Entity.FireBullets( entity, bulletInfo )
local weapon = pGetActiveWeapon(me):GetClass();
PA.SpreadTable[weapon] = bulletInfo.Spread;
return CleanRegistry.Entity.FireBullets( entity, bulletInfo );
end
function PA.PredictSpread( cmd, viewAngle )
local weapon = pGetActiveWeapon(me)
if ( !eIsValid(weapon) || PA.SpreadTable[weapon:GetClass()] == nil || !PA.VAR["PA_NOSPREAD"]) then return viewAngle; end
local x,y = PA.SpreadTable[weapon:GetClass()].x,PA.SpreadTable[weapon:GetClass()].y;
return( DS_manipulateShot( DS_md5PseudoRandom( cCommandNumber(cmd) ), aForward(viewAngle), Vector( -x , -y , 0 ) ) ):Angle();
end
local function restoreAutism(userCmd) cSetViewAngles(userCmd, PA.PredictSpread(userCmd,ms) ) end
local function BHOP(userCmd)
if ( PA.VAR["PA_BHOP"] && !me:IsTyping() && !eIsOnGround(me) && !me:IsFlagSet(FL_PARTIALGROUND) ) then
userCmd:RemoveKey( 2 );
local mouseX = cGetMouseX(userCmd);
if ( mouseX < 0 ) then
cSetSideMove(userCmd, -10^4 );
elseif ( mouseX > 0 ) then
cSetSideMove(userCmd, 10^4 );
end
end
end
local function NameSteal()
if(!PA.VAR["PA_NAMESTEAL"]) then return; end
local hacker = player.GetAll()
for k,v in next,hacker do
if(v == me || string.find(v:Nick(), me:Nick())) then table.remove(hacker,k); end
end
GetConVar("name"):SetValue(table.Random(hacker):Nick() .. "");
end
// Razor the hack he give me this u know
// Thanks to razor for this hacker meme, its pFunny
// I DID NOT MAKE THIS!
hackerModeLetters = {};
local function paintHackerMode()
if(!PA.VAR["PA_HACKERMODE"]) then hackerModeLetters = {}; return; end
local maxDists = ScrW() / 5;
if(#hackerModeLetters < 125) then
for i = 0, 150 do
hackerModeLetters[#hackerModeLetters + 1] = {
-20,
5 * math.random(maxDists),
math.random(1, 15),
}
end
end
for k,v in next, hackerModeLetters do
// surface.SetFont("BudgetLabel");
v[1] = v[1] + v[3];
if(v[1] >= ScrH()) then
table.remove(hackerModeLetters, k);
continue;
end
surface.SetFont( "ChatFont" )
local spook = "-" .. math.random(1,95) .. "%";
surface.SetTextColor(255, 255, 255);
surface.SetTextPos(v[2], v[1]);
draw****undedBox(0,v[2] - 5, v[1],surface.GetTextSize(spook) + 10,15,Color(6, 230, 0));
surface.DrawText(spook);
end
end
local say = {
"PA " .. pa_version .. " | Registered Aim-ware Rapist",
"PA " .. pa_version .. " | Because Your cheats are not good enough!",
}
local function SpamChat()
if(!PA.VAR["PA_SPAM"]) then return; end
local random = table.Random(player.GetAll());
LocalPlayer():ConCommand("say " .. table.Random(say));
end
local function CrossHair()
if(!PA.VAR["PA_CROSSHAIR"]) then return; end
local mx = ScrW() / 2
local my = ScrH() / 2
surface.SetDrawColor(Color(0,255,0))
surface.DrawLine(mx - 0.5, my - 40, mx - 0.5, my + 40 )
surface.DrawLine(mx + 40, my - 0.5, mx - 40, my - 0.5 )
surface.DrawOutlinedRect(mx - 10.5,my - 10.5,20,20)
end
local function SpeedHack()
if(input.IsKeyDown(PA.VAR["PA_SPEEDHACK_KEY"]) && PA.VAR["PA_SPEEDHACK"]) then
GetConVar("sv_cheats"):SetValue(1)
GetConVar("host_timescale"):SetValue(5)
else
GetConVar("sv_cheats"):SetValue(0)
GetConVar("host_timescale"):SetValue(1)
end
end
local function SkeletonESP(v)
local origin = eGetPos(v);
for i = 1, eGetBoneCount(v) do
local parent = eGetBoneParent(v,i);
local bonepos, parentpos = eGetBonePosition(v,i), eGetBonePosition(v,parent);
if(!parent || !bonepos || !parentpos || bonepos == origin) then continue; end
local bs, ps = vToScreen(bonepos), vToScreen(parentpos)
if(pTeam(v) == pTeam(me)) then surface.SetDrawColor(0,255,0); else surface.SetDrawColor(255,0,0); end
surface.DrawLine(bs.x, bs.y, ps.x, ps.y);
end
end
local function ESP(target)
local min, max, width, height;
min = target:GetPos()
max = min + Vector( 0, 0, eOBBMaxs(target).z )
min, max = vToScreen(min), vToScreen(max)
height = min.y - max.y;
width = height *.5;
draw.DrawText( pNick(target) .. "(" .. target:Ping() .. "ms)\n" .. target:GetUserGroup(), "espFont", max.x + ( width / 2 ), max.y + ( height / 2 ), Color(255,255,255), TEXT_ALIGN_LEFT )
end
local function XRAY()
cam.Start3D()
for k,v in pairs(player.GetAll()) do
if(v == me) then continue; end
if(v:Team() == me:Team()) then
render.SetColorModulation(0,1,0)
else
render.SetColorModulation(1,0,0)
end
render.SuppressEngineLighting(true)
render.SetBlend(1)
v:DrawModel()
end
cam.End3D()
end
local function ESPfunc()
for k,v in next, player.GetAll() do
if (!IsValid(v)) then continue; end
if (v == me) then continue; end
if (!pAlive(v)) then continue; end
if(PA.VAR["PA_ESP"]) then
ESP(v);
end
if(PA.VAR["PA_ESP_SKELETON"]) then
SkeletonESP(v);
end
end
if(PA.VAR["PA_ESP"]) then
// XRAY();
end
end
local function GetCurTime()
if(!IsFirstTimePredicted()) then return; end
servertime = CurTime() + GetTick;
end
local function CanFire()
local wep = pGetActiveWeapon(me)
if(!IsValid(wep)) then return false; end
return( servertime >= wGetNextPrimaryFire(wep) );
end
PA.PredCount = {}
PA.PredOld = {}
local function FakeLagPrediction(ent)
// nein
return 0;
end
local function insight(v,vec)
local trace = { }
trace.start = pShootPos(me)
trace.endpos = vec
trace.mask = 1174421507
trace.filter = { v , me }
return !util.TraceLine( trace ).Hit
end
local function hitBoxReturn(ent,hitbox0,hitbox1,bone)
local bone = eLookupBone(ent, bone);
if(!bone) then return Angle(); end
local min,max = eGetHitBoxBounds(ent,hitbox0,hitbox1);
local pos, ang = eGetBonePosition(ent,bone);
return pos + (( min + max) * .5);
end
local function ReturnBone(ent)
local bodyobb = eLocalToWorld(ent,eOBBCenter(ent));
local canSeePlayer = insight(ent,eLocalToWorld(ent,bodyobb));
if(PA.VAR["PA_ATTACHMENTS"]) then
if(PA.VAR["PA_BODYAIM"] && canSeePlayer ) then
if(eLookupAttachment(ent,"chest") != 0) then
local eyes = eGetAttachment(ent,eLookupAttachment(ent,"chest")).Pos
if(insight(ent,eyes)) then return {true, eyes}; end
end
else
if(eLookupAttachment(ent,"forward") != 0) then
local bone = eGetAttachment(ent,eLookupAttachment(ent,"forward")).Pos
if(insight(ent,bone)) then return {true, bone}; end
end
if(PA.VAR["PA_BONESCAN_AIM"] && canSeePlayer) then
for k,v in next, ent:GetAttachments() do
if(eLookupAttachment(ent,v.name) != 0) then
local bone = eGetAttachment(ent,eLookupAttachment(ent,v.name)).Pos
if(insight(ent,bone)) then return {true, bone}; end
end
end
else
if(eLookupAttachment(ent,"eyes") != 0) then
local bone = eGetAttachment(ent,eLookupAttachment(ent,"eyes")).Pos
if(insight(ent,bone)) then return {true, bone}; end
end
end
end
else
if(PA.VAR["PA_BODYAIM"] ) then
local pos = hitBoxReturn(ent,16,0,"ValveBiped.Bip01_Spine");
if(insight(ent,pos)) then return {true,pos}; end
else
local pos = hitBoxReturn(ent,0,0,"ValveBiped.Bip01_Head1");
if(insight(ent,pos)) then return {true,pos}; end
if(PA.VAR["PA_BONESCAN_AIM"]) then
local hitBoxGroup = eGetHitBoxGroupCount(ent);
for i = 0, hitBoxGroup -1 do
for m = 0,eGetHitBoxCount(ent,i) do
local pos = hitBoxReturn(ent,m,i);
if(insight(ent,pos)) then return {true,pos}; end
end
end
end
end
end
if(PA.VAR["PA_BODYAIM_ERROR"]) then
if(insight(ent,canSeePlayer)) then return {true,bodyobb}; end
end
return{false,Vector()};
end
PA.AimAtBone = nil;
local function CANSEE(ent)
local BoneResult = ReturnBone(ent);
if(BoneResult[1]) then
return {vis = BoneResult[1],pos = BoneResult[2],them = ent};
else
return {vis = false, pos = nil, them = nil};
end
end
local function GetNearest()
local tbla = player.GetAll();
table.sort(tbla,CPE);
for k,v in next, tbla do
if (v == me) then continue; end
if (!pAlive(v)) then continue; end
if (PA.VAR["PA_ONLY_TARGET_TEAM"] && pTeam(v) != pTeam(me)) then continue; end
if (!PA.VAR["PA_TARGET_TEAM"] && !PA.VAR["PA_ONLY_TARGET_TEAM"] && pTeam(me) == pTeam(v)) then continue; end
if (!PA.VAR["PA_TARGET_FRIENDS"] && v:GetFriendStatus() == "friend") then continue; end
local CANSEE_BONE = CANSEE(v);
if (!CANSEE_BONE.vis) then continue; end
return CANSEE_BONE;
end
return {false,nil,nil};
end
local function UnFuckMouse(userCmd)
if (!ms) then ms = cGetViewAngles(userCmd) end
ms = ms + Angle(cGetMouseY(userCmd) * .023, cGetMouseX(userCmd) * -.023, 0);
ms.x = math.NormalizeAngle(ms.x);
ms.p = math.Clamp(ms.p, -89, 89);
end
local function CalcView(me,origin,angles)
glob_origin = origin;
local view = {}
view.angles = ms
view.vm_angles = ms
if(PA.VAR["PA_THIRDPERSON"] ) then
view.origin = glob_origin-( aForward(ms)*125 )
else
view.origin = glob_origin;
end
view.fov = PA.VAR["PA_FOV"];
return view;
end
local function FixMovement(cmd)
local GetFix = Vector(cGetForwardMove(cmd), cGetSideMove(cmd), 0)
GetFix = aForward(GetFix:Angle() + cGetViewAngles(cmd) - ms) * vLength(GetFix);
cSetForwardMove(cmd,GetFix.x)
cSetSideMove(cmd,GetFix.y)
end
local aaJam = 0;
PA.AATbl = {1,4,7,10};
local aaLoop =1;
local function FakeAngles(cmd)
if(!CanFire() && cKeyDown(cmd, IN_ATTACK ) || !pAlive(me) || !PA.VAR["PA_ANTI_AIM"]) then cSetViewAngles(cmd,ms); PA4.CHOKE_PACKETS(false); return; end
local startAngle = Angle();
local chokeAngle = false;
if(PA.VAR["PA_ANTI_AIM_TYPE"] == 1) then
// nein
end
PA4.CHOKE_PACKETS(chokeAngle);
cSetViewAngles(cmd,startAngle);
end
local function AAA_Fix_Semi()
if(!PA.VAR["PA_ANTI_ANTI_AIM"]) then return; end
for k,v in next, player.GetAll() do
eSetPoseParameter(v,"aim_pitch",0);
eInvalidateBoneCache(v);
end
end
local function CreateMove(userCmd)
UnFuckMouse(userCmd);
GetCurTime();
//AAA_Fix_Semi();
local aimshit = GetNearest();
local CanFires = aimshit.vis && CanFire();
if(!PA.VAR["PA_FAKELAG"] && PA.VAR["PA_PSILENT_AIM"]) then PA4.CHOKE_PACKETS(false); end
if (PA.VAR["PA"] && PA.VAR["PA_AUTO_SHOOT"] && CanFires || cKeyDown(userCmd, IN_ATTACK ) && PA.VAR["PA"] && !PA.VAR["PA_AUTO_SHOOT"] && CanFires ) then
local aimAngle = vAngle(( (
aimshit.pos - pShootPos(me)
- ( ( eGetVelocity(me) * engine.TickInterval() ) ) )));
aimAngle.x = -180 - aimAngle.x + 720;
aimAngle.y = aimAngle.y +180;
aimAngle.r = 0;
cSetButtons(userCmd, bit.bor(cGetButtons(userCmd), IN_ATTACK));
if(!PA.VAR["PA_FAKELAG"] && PA.VAR["PA_PSILENT_AIM"]) then PA4.CHOKE_PACKETS(true); end
cSetViewAngles(userCmd,PA.PredictSpread(userCmd,aimAngle));
else
FakeAngles(userCmd);
end
FixMovement(userCmd)
end
local menuTabs = {};
local menuKeyPress = {open = false, open2 = false,open3 = false};
local menuMovement = {down = false, up = false, up2 = false, left = false, right = false};
local menuVariables = {menuSub = 1,Options = 0, Selected = 1, TotalOpt = 0}
local menuIsStateMents = {};
local menuSubMenus = {};
local menuOptions = {};
local function FromBool(bool)
if(bool) then
return 1;
else
return 0;
end
end
local PA_OPTS = {
["Aimbot Settings"] =
{
{name = "Aimbot", dvalue = FromBool(PA.VAR["PA"]), min = 0, max = 1, func = function(ID) PA.VAR["PA"] = ID == 1; end, motd = "test"},
{name = "Rage-Mode", dvalue = FromBool(PA.VAR["PA_AUTO_SHOOT"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_AUTO_SHOOT"] = ID == 1; end},
{name = "Attachment Aim", dvalue = FromBool(PA.VAR["PA_ATTACHMENTS"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_ATTACHMENTS"] = ID == 1; end},
{name = "Body-Aim", dvalue = FromBool(PA.VAR["PA_BODYAIM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_BODYAIM"] = ID == 1; end},
{name = "Body-Aim Error Models", dvalue = FromBool(PA.VAR["PA_BODYAIM_ERROR"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_BODYAIM_ERROR"] = ID == 1; end},
{name = "Bone-Scan", dvalue = FromBool(PA.VAR["PA_BONESCAN_AIM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_BONESCAN_AIM"] = ID == 1; end},
{name = "Silent-Aim", dvalue = FromBool(PA.VAR["PA_SILENT_AIM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_SILENT_AIM"] = ID == 1; end},
{name = "pSilent-Aim", dvalue = FromBool(PA.VAR["PA_PSILENT_AIM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_PSILENT_AIM"] = ID == 1; end},
{name = "Target-Team", dvalue = FromBool(PA.VAR["PA_TARGET_TEAM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_TARGET_TEAM"] = ID == 1; end},
{name = "Only Target-Team", dvalue = FromBool(PA.VAR["PA_ONLY_TARGET_TEAM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_ONLY_TARGET_TEAM"] = ID == 1; end},
{name = "Target-Friends", dvalue = FromBool(PA.VAR["PA_TARGET_FRIENDS"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_TARGET_FRIENDS"] = ID == 1; end},
},
["HVH Settings"] =
{
{name = "No-Spread", dvalue = FromBool(PA.VAR["PA_NOSPREAD"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_NOSPREAD"] = ID == 1; end},
{name = "Anti-Aim", dvalue = FromBool(PA.VAR["PA_ANTI_AIM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_ANTI_AIM"] = ID == 1; end},
{name = "Anti-Aim-Type", dvalue = PA.VAR["PA_ANTI_AIM_TYPE"], min = 1, max = 4, func = function(ID) PA.VAR["PA_ANTI_AIM_TYPE"] = ID; end},
{name = "Anti-Anti-Aim", dvalue = FromBool(PA.VAR["PA_ANTI_ANTI_AIM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_ANTI_ANTI_AIM"] = ID == 1; PA4.AAAX(ID == 1);PA4.AAAY(ID == 1) end},
{name = "Anti-Anti-Anti-Aim Chew", dvalue = PA.VAR["PA_ANTI_ANTI_ANTI_AIM_PACKETS"], min = 1 , max = 15, func = function(ID) PA.VAR["PA_ANTI_ANTI_ANTI_AIM_PACKETS"] = ID; end},
{name = "Anti-Anti-Anti-Aim Spit", dvalue = 1, min = 1 , max = 1, func = function(ID) end},
{name = "Fake-Lag Prediction", dvalue = FromBool(PA.VAR["PA_FAKELAG_PRED"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_FAKELAG_PRED"] = ID == 1; end},
{name = "Fake-Lag", dvalue = FromBool(PA.VAR["PA_FAKELAG"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_FAKELAG"] = ID == 1; PA4.FAKELAG(ID == 1); end},
{name = "Fake-Lag Send Packets ", dvalue = 15, min = 2, max = 15, func = function(ID) end},
{name = "Fake-Lag Choke Packets", dvalue = 3, min = 1, max = 15, func = function(ID) end},
},
["Misc"] =
{
{name = "Speed-Hack", dvalue = FromBool(PA.VAR["PA_SPEEDHACK"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_SPEEDHACK"] = ID == 1; end},
{name = "Auto-Bunny Hop", dvalue = FromBool(PA.VAR["PA_BHOP"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_BHOP"] = ID == 1; end},
{name = "ESP", dvalue = FromBool(PA.VAR["PA_ESP"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_ESP"] = ID == 1; end},
{name = "Cross-Hair", dvalue = FromBool(PA.VAR["PA_CROSSHAIR"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_CROSSHAIR"] = ID == 1; end},
{name = "Skeleton ESP", dvalue = FromBool(PA.VAR["PA_ESP_SKELETON"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_ESP_SKELETON"] = ID == 1; end},
{name = "Name Steal", dvalue = FromBool(PA.VAR["PA_NAMESTEAL"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_NAMESTEAL"] = ID == 1; end},
{name = "Chat Spam", dvalue = FromBool(PA.VAR["PA_SPAM"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_SPAM"] = ID == 1; end},
{name = "ThirdPerson", dvalue = FromBool(PA.VAR["PA_THIRDPERSON"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_THIRDPERSON"] = ID == 1; end},
{name = "Steam Sale Mode", dvalue = FromBool(PA.VAR["PA_HACKERMODE"]), min = 0, max = 1, func = function(ID) PA.VAR["PA_HACKERMODE"] = ID == 1;
if(PA.VAR["PA_HACKERMODE"]) then
sound.PlayURL ( "netrd", "", function( memesound1 )
if(memesound1) then
memesound1:Play();
memesound12 = memesound1;
end
end)
else
if memesound12:IsValid() then
memesound12:Stop();
memesound12 = nil;
end
end
end},
},
["Menu Settings"] =
{
{name = "Menu Position", dvalue = PA.VAR["PA_MENU_POSITION"], min = 1, max = 3, func = function(ID) PA.VAR["PA_MENU_POSITION"] = ID; end},
{name = "Menu Color[R]", dvalue = PA.VAR["PA_MENU_COLOR"].r, min = 0, max = 255, func = function(ID) PA.VAR["PA_MENU_COLOR"].r = ID; end},
{name = "Menu Color[G]", dvalue = PA.VAR["PA_MENU_COLOR"].g, min = 0, max = 255, func = function(ID) PA.VAR["PA_MENU_COLOR"].g = ID; end},
{name = "Menu Color[B]", dvalue = PA.VAR["PA_MENU_COLOR"].b, min = 0, max = 255, func = function(ID) PA.VAR["PA_MENU_COLOR"].b = ID; end},
{name = "Menu Color[A]", dvalue = PA.VAR["PA_MENU_COLOR"].a, min = 0, max = 255, func = function(ID) PA.VAR["PA_MENU_COLOR"].a = ID; end},
{name = "Menu Rainbow", dvalue = FromBool(PA.VAR["PA_MENU_COLOR"].rainbow), min = 0, max = 1, func = function(ID) PA.VAR["PA_MENU_COLOR"].rainbow = ID == 1; end},
{name = "Menu Rainbow[SPEED]", dvalue = PA.VAR["PA_MENU_COLOR"].rainbow_speed, min = 5, max = 120, func = function(ID) PA.VAR["PA_MENU_COLOR"].rainbow_speed = ID; end},
}
}
local showtabs = {}
local menuopen, selmade
local showtabs = {}
local function Menu()
local main = vgui.Create("DFrame")
main:SetSize(ScrW(),ScrH())
main:SetTitle("")
main:ShowCloseButton(false)
main:SetDraggable(false)
main:SetPos(25, 25)
local PA_SELECTED_OPT = 0
function main:Paint(w, h)
menuVariables.TotalOpt = 0
local GHeight = 25
surface.SetFont("BudgetLabel")
surface.SetDrawColor(Color(25, 25, 25, 150))
surface.DrawRect(0, 0, w, 25)
surface.SetDrawColor(Color(40, 40, 40, 150))
surface.DrawRect(0, 25, w, h)
surface.SetTextPos(5, 5)
surface.SetTextColor(Color(255,255,255, 255))
surface.DrawText("PA " .. pa_version .. " By 2cash")
for k,v in pairs(PA_OPTS) do
menuVariables.TotalOpt = menuVariables.TotalOpt + 1
local citem = menuVariables.TotalOpt
if (menuVariables.Selected == citem) then
if (PA_SELECTED_OPT != 0) then
showtabs[k] = !showtabs[k]
PA_SELECTED_OPT = 0
end
if(PA.VAR["PA_MENU_COLOR"].rainbow) then
surface.SetDrawColor(HSVToColor(RealTime()*PA.VAR["PA_MENU_COLOR"].rainbow_speed%360,1,1));
else
surface.SetDrawColor(Color(PA.VAR["PA_MENU_COLOR"].r, PA.VAR["PA_MENU_COLOR"].g, PA.VAR["PA_MENU_COLOR"].b,PA.VAR["PA_MENU_COLOR"].a))
end
surface.DrawRect(0, GHeight, 350, 15)
surface.SetDrawColor(Color(40, 40, 40))
//surface.DrawOutlinedRect(1, GHeight, 348, 16)
end
surface.SetTextPos(5, GHeight)
surface.DrawText((showtabs[k] and "[-] - " or "[+] - ")..k)
GHeight = GHeight + 15
if (!showtabs[k]) then continue end
for _, var in pairs(PA_OPTS[k]) do
menuVariables.TotalOpt = menuVariables.TotalOpt + 1
local curitem = menuVariables.TotalOpt
if (menuVariables.Selected == curitem) then
if (PA_SELECTED_OPT != 0) then
if (k == "Menu" && string.find(PA_OPTS[k][_].name, "Pos")) then PA_SELECTED_OPT = PA_SELECTED_OPT * 5 end
if(PA_OPTS[k][_].dvalue >= PA_OPTS[k][_].max ) then
PA_OPTS[k][_].dvalue = PA_OPTS[k][_].min;
else
PA_OPTS[k][_].dvalue = (PA_OPTS[k][_].dvalue + PA_SELECTED_OPT >= PA_OPTS[k][_].min && PA_OPTS[k][_].dvalue + PA_SELECTED_OPT || PA_OPTS[k][_].dvalue)
end
PA_OPTS[k][_].func(PA_OPTS[k][_].dvalue);
PA_SELECTED_OPT = 0
end
if(PA_OPTS[k][_].motd != nil) then
draw.DrawText("Test", "BudgetLabel", 350,25)
end
if(PA.VAR["PA_MENU_COLOR"].rainbow) then
surface.SetDrawColor(HSVToColor(RealTime()*PA.VAR["PA_MENU_COLOR"].rainbow_speed%360,1,1));
else
surface.SetDrawColor(Color(PA.VAR["PA_MENU_COLOR"].r, PA.VAR["PA_MENU_COLOR"].g, PA.VAR["PA_MENU_COLOR"].b,PA.VAR["PA_MENU_COLOR"].a))
end
surface.DrawRect(0, GHeight, 350, 16)
surface.SetDrawColor(Color(40, 40, 40))
surface.DrawOutlinedRect(1, GHeight, 348, 16)
end
local val = PA_OPTS[k][_].dvalue
surface.SetTextPos(15, GHeight)
if (PA_OPTS[k][_].name != "") then
surface.DrawText(PA_OPTS[k][_].name)
surface.SetTextPos(325, GHeight)
surface.DrawText(val)
end
surface.SetTextPos(15, GHeight)
GHeight = GHeight + 15
end
end
if(PA.VAR["PA_MENU_POSITION"] == 1) then
main:SetSize(350, GHeight + 5)
main:SetPos(50,50)
else if(PA.VAR["PA_MENU_POSITION"] == 2) then
main:SetSize(350, GHeight + 5)
main:SetPos(ScrW() / 2 - (350 / 2),ScrH() / 2 - (GHeight + 5))
else if(PA.VAR["PA_MENU_POSITION"] == 3) then
main:SetSize(350, GHeight + 5)
main:SetPos(ScrW() / 2 - (350 / 2),ScrH() - (GHeight + 5))
end
end
end
if(PA.VAR["PA_MENU_COLOR"].rainbow) then
surface.SetDrawColor(HSVToColor(RealTime()*PA.VAR["PA_MENU_COLOR"].rainbow_speed%360,1,1));
else
surface.SetDrawColor(Color(PA.VAR["PA_MENU_COLOR"].r, PA.VAR["PA_MENU_COLOR"].g, PA.VAR["PA_MENU_COLOR"].b,PA.VAR["PA_MENU_COLOR"].a))
end
surface.DrawOutlinedRect(0, 0, 350, GHeight + 5)
end
local buttonDelay = CurTime();
function main:Think()
if (input.IsKeyDown(KEY_UP) && !menuMovement.up) then
if (menuVariables.Selected - 1 > 0) then
menuVariables.Selected = menuVariables.Selected - 1
end
menuMovement.up = true
elseif (!input.IsKeyDown(KEY_UP)) then
menuMovement.up = false
end
if (input.IsKeyDown(KEY_DOWN) && !menuMovement.down) then
if (menuVariables.Selected < menuVariables.TotalOpt) then
menuVariables.Selected = menuVariables.Selected + 1
end
menuMovement.down = true
elseif (!input.IsKeyDown(KEY_DOWN)) then
menuMovement.down = false
end
if (input.IsKeyDown(KEY_LEFT) && !menuMovement.left) then
PA_SELECTED_OPT = -1
menuMovement.left = true
elseif (!input.IsKeyDown(KEY_LEFT)) then
menuMovement.left = false
end
if (input.IsKeyDown(KEY_RIGHT) && !menuMovement.right) then
PA_SELECTED_OPT = 1
menuMovement.right = true
elseif (!input.IsKeyDown(KEY_RIGHT)) then
menuMovement.right = false
end
if (input.IsKeyDown(KEY_INSERT) && !menuMovement.open3) then
main:Close()
menuMovement.open = false
end
end
end
hook.Add("Think", "", function()
if (input.IsKeyDown(KEY_INSERT) && !menuMovement.open && !menuMovement.open2) then
menuMovement.open = true
menuMovement.open2 = true
Menu()
elseif (!input.IsKeyDown(KEY_INSERT) && !menuMovement.open) then
menuMovement.open2 = false
end
if (input.IsKeyDown(KEY_INSERT) && menuMovement.open2 && menuMovement.open) then
menuMovement.open3 = true
else
menuMovement.open3 = false
end
end)
oCreateMove = oCreateMove or GAMEMODE.CreateMove;
oHUDPaint = oHUDPaint or GAMEMODE.HUDPaint;
oMove = oHUDPaint or GAMEMODE.Move;
function GAMEMODE:CreateMove( userCmd )
// pa.alltable = player.getall(); table.sort(pa.alltable, closestplayerexpression);
BHOP(userCmd);
CreateMove( userCmd );
SpeedHack();
NameSteal();
SpamChat();
//oCreateMove( userCmd );
end
GAMEMODE["Move"] = function()
GetCurTime();
end
GAMEMODE["HUDPaint"] = function(self)
ESPfunc();
//MakeMenu();
CrossHair();
paintHackerMode();
oHUDPaint(self);
end
GAMEMODE["Think"] = function()
//FullBright()
//norec()
end
GAMEMODE["ShouldDrawLocalPlayer"] = function(me)
return PA.VAR["PA_THIRDPERSON"];
end
GAMEMODE["GetViewModelPosition"] = function(pos,ang)
return glob_origin, ms;
end
GAMEMODE["CalcViewModelView"] = function(wep, vm, oldPos, oldAng, pos, ang)
return glob_origin, ms;
end
hook.Add("CalcView","PA_AIMBOT_VIEW",CalcView)