LUA скрипт Lunar.lua leak

Забаненный
Статус
Оффлайн
Регистрация
21 Июн 2021
Сообщения
85
Реакции[?]
10
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Код:
username = Cheat.GetCheatUserName()

local ffi = require("ffi")
local shell = ffi.load("Shell32.dll")

ffi.cdef[[
    int ShellExecuteA(void* hwnd, const char* lpOperation, const char* lpFile, const char* lpParameters, const char* lpDirectory, int nShowCmd);
]]

-- REFERENCES
local leg_move = Menu.FindVar("Aimbot", "Anti Aim", "Misc", "Leg Movement")
local ref_yaw = Menu.FindVar("Aimbot", "Anti Aim", "Main", "Yaw Base")
local ref_pitch = Menu.FindVar("Aimbot", "Anti Aim", "Main", "Pitch")
local ref_slowwalk = Menu.FindVar("Aimbot", "Anti Aim", "Misc", "Slow Walk")
local ref_left_limit = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Left Limit")
local ref_right_limit = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Right Limit")
local ref_fake_options = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Fake Options")
local ref_lby_mode = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "LBY Mode")
local ref_freestand_desync = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Freestanding Desync")
local ref_desync_on_shot = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Desync On Shot")
local ref_anti_aim_enable = Menu.FindVar("Aimbot", "Anti Aim", "Main", "Enable Anti Aim")
local ref_inverter = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Inverter")



-- MENU ITEMS
Menu.Text("xoxasync", "Welcome to xoxasync " .. username .. "!")
Menu.Button("xoxasync", "Discord", "Join our discord", function()
shell.ShellExecuteA(nil, "open", "https://discord.gg/7tMGemzj84", nil, nil, 0)
end)

--AA
local enable_antiaim = Menu.Switch("Anti-Aim", "Enable", false, "Enable anti-aim")
local aa_modes = Menu.Combo("Anti-Aim", "Anti-aim mode", {"None", "Aggresive", "Dynamic"}, 0, "Anti-aim modes")
local freestand_type = Menu.Combo("Anti-Aim", "Freestanding type", {"Normal", "Xoxaverse"}, 0, "Freestanding modes")
-- local anti_brute = Menu.Switch("Anti-Aim", "Anti brute-force", false, "Change desync side on miss")
local anti_brute = Menu.Combo("Anti-Aim", "Anti Bruteforce", {"Off", "Normal", "Xoxa brute"}, 0, "")
local low_delta_slow = Menu.Switch("Anti-Aim", "Low delta on slow walk", false, "Low delta while slow-walking")
local legitaa = Menu.Switch("Anti-Aim", "Legit Anti Aim on use", false, "Legit AA while you hold E")
local disable_warmup = Menu.Switch("Anti-Aim", "Disable on warmup", false, "Disables AA on warmup")

-- RAGE
local enable_rage = Menu.Switch("Rage", "Enable", false, "Enable rage")
local enable_dt = Menu.Switch("Rage", "Doubletap", false, "Enables double tap modifier")
local dt_mode = Menu.Combo("Rage", "Doubletap modes", {"Fast", "xoxatap"}, 0, "Doubletap modes")
local disable_correction = Menu.Switch("Rage", "Disable Correction", false, "Disable clock correction")
-- local dormant_aimbot = Menu.Switch("Rage", "Dormant Aimbot", false, "Shoots the target while its dormant")
-- local da_dmg = Menu.SliderInt("Rage", "Dormant Damage", 1, 0, 100, "Dormant aimbot minimum damage")     
local anti_defensive = Menu.Button("Rage", "Anti Defensive", "Anti defensive double tap", function()
    EngineClient.ExecuteClientCmd("jointeam 1 1")

    CVar.FindVar("cl_lagcompensation"):SetInt(0)
    -- CVar.FindVar("cl_predict"):SetInt(0)
end)


-- VISUALS
local enable_visuals = Menu.Switch("Visuals", "Enable", false, "Enable visuals")
local indicator_type = Menu.Combo("Visuals", "Indicator type", {"Acatel", "Dynamic"}, 0, "Indicators type")
local pulsate_alpha = Menu.Switch("Visuals", "Pulsating indicator", false, "Pulsates 'sync' indicator")
local teamskeet_arrows = Menu.Switch("Visuals", "Anti aim arrows", false, "'Team sk33t' arrows")
local visual_color = Menu.ColorEdit("Visuals", "Color", Color.new(1.0, 1.0, 1.0, 1.0), "Indicator color")
local second_color = Menu.ColorEdit("Visuals", "Second Color", Color.new(1.0, 1.0, 1.0, 1.0), "Second indicator color")
local indicators = Menu.MultiCombo("Visuals", "Additional indicators", {"Min Damage", "Body Aim", "Safe Point"}, 0)

-- MISC
local enable_misc = Menu.Switch("Misc", "Enable", false, "Enable misc")
local leg_fucker = Menu.Switch("Misc", "Leg fucker", false, "Randomize leg movement")
local trashtalk = Menu.Switch("Misc", "Trastalk", false, "Trashtalks enemy when you kill")

Menu.Text("Updates", "Last update: 8th October")
Menu.Text("Updates", " - Improved everything")


local function handle_binds()
    local binds = Cheat.GetBinds()
    for i = 1, #binds do
        if binds[i]:GetName() == "Minimum Damage" and binds[i]:IsActive() then
        min_dmg = true
        min_dmg_dmg = binds[i]:GetValue()
        end
        if binds[i]:GetName() == "Minimum Damage" and not binds[i]:IsActive() then
            min_dmg = false
        end
    
        if binds[i]:GetName() == "Double Tap" and binds[i]:IsActive() then
        doubletap = true
        end
        if binds[i]:GetName() == "Double Tap" and not binds[i]:IsActive() then
        doubletap = false
        end
    
        if binds[i]:GetName() == "Hide Shots" and binds[i]:IsActive() then
        hideshots = true
        end
        if binds[i]:GetName() == "Hide Shots" and not binds[i]:IsActive() then
        hideshots = false
        end
    
        if binds[i]:GetName() == "Auto Peek" and binds[i]:IsActive() then
        quickpeek = true
        end
        if binds[i]:GetName() == "Auto Peek" and not binds[i]:IsActive() then
        quickpeek = false
        end
    
        if binds[i]:GetName() == "Fake Duck" and binds[i]:IsActive() then
        fakeduck = true
        end
        if binds[i]:GetName() == "Fake Duck" and not binds[i]:IsActive() then
        fakeduck = false
        end

        if binds[i]:GetName() == "Body Aim" and binds[i]:IsActive() then
        bodyaim = true
        end
        if binds[i]:GetName() == "Body Aim" and not binds[i]:IsActive() then
        bodyaim = false
        end

        if binds[i]:GetName() == "Safe Points" and binds[i]:IsActive() then
        safepoint = true
        end
        if binds[i]:GetName() == "Safe Points" and not binds[i]:IsActive() then
        safepoint = false
        end
    
        if binds[i]:GetName() == "Yaw Base" and binds[i]:IsActive() then
        manual_aa = true
        manual_aa_side = binds[i]:GetValue()
        end
        if binds[i]:GetName() == "Yaw Base" and not binds[i]:IsActive() then
        manual_aa = false
        end

    end
end

local ffi = require("ffi")
local bit = require("bit")
local cast = ffi.cast
local unpack = table.unpack
local bor = bit.bor
local buff = {free = {}}
local vmt_hook = {hooks = {}}
local target = Utils.CreateInterface("vgui2.dll", "VGUI_Panel009")
local interface_type = ffi.typeof("void***")
-- gamesense renderer start
local renderer = {}


ffi.cdef[[
    int VirtualProtect(void* lpAddress, unsigned long dwSize, unsigned long flNewProtect, unsigned long* lpflOldProtect);
    void* VirtualAlloc(void* lpAddress, unsigned long dwSize, unsigned long  flAllocationType, unsigned long flProtect);
    int VirtualFree(void* lpAddress, unsigned long dwSize, unsigned long dwFreeType);
    typedef unsigned char wchar_t;
    typedef int(__thiscall* ConvertAnsiToUnicode_t)(void*, const char*, wchar_t*, int);
    typedef int(__thiscall* ConvertUnicodeToAnsi_t)(void*, const wchar_t*, char*, int);
    typedef wchar_t*(__thiscall* FindSafe_t)(void*, const char*);
    typedef void(__thiscall* draw_set_text_color_t)(void*, int, int, int, int);
    typedef void(__thiscall* draw_set_color_t)(void*, int, int, int, int);
    typedef void(__thiscall* draw_filled_rect_fade_t)(void*, int, int, int, int, unsigned int, unsigned int, bool);
    typedef void(__thiscall* draw_set_text_font_t)(void*, unsigned long);
    typedef void(__thiscall* get_text_size_t)(void*, unsigned long, const wchar_t*, int&, int&);
    typedef void(__thiscall* draw_set_text_pos_t)(void*, int, int);
    typedef void(__thiscall* draw_print_text_t)(void*, const wchar_t*, int, int);
    typedef void(__thiscall* set_font_glyph_t)(void*, unsigned long, const char*, int, int, int, int, unsigned long, int, int);
    typedef unsigned int(__thiscall* create_font_t)(void*);
]]

local get_panel_name_type = ffi.typeof("const char*(__thiscall*)(void*, uint32_t)")

local panel_interface = ffi.cast(interface_type, target) --
local panel_interface_vtbl = panel_interface[0] --
local get_panel_name_raw = panel_interface_vtbl[36] --
local get_panel_name = ffi.cast(get_panel_name_type, get_panel_name_raw)  -- credits to alphanine

local function uuid(len)
    local res, len = "", len or 32
    for i=1, len do
        res = res .. string.char(Utils.RandomInt(97, 122))
    end
    return res
end

local interface_mt = {}

function interface_mt.get_function(self, index, ret, args)
    local ct = uuid() .. "_t"

    args = args or {}
    if type(args) == "table" then
        table.insert(args, 1, "void*")
    else
        return error("args has to be of type table", 2)
    end
    local success, res = pcall(ffi.cdef, "typedef " .. ret .. " (__thiscall* " .. ct .. ")(" .. table.concat(args, ", ") .. ");")
    if not success then
        error("invalid typedef: " .. res, 2)
    end

    local interface = self[1]
    local success, func = pcall(ffi.cast, ct, interface[0][index])
    if not success then
        return error("failed to cast: " .. func, 2)
    end

    return function(...)
        local success, res = pcall(func, interface, ...)

        if not success then
            return error("call: " .. res, 2)
        end

        if ret == "const char*" then
            return res ~= nil and ffi.string(res) or nil
        end
        return res
    end
end

local function create_interface(dll, interface_name)
    local interface = (type(dll) == "string" and type(interface_name) == "string") and Utils.CreateInterface(dll, interface_name) or dll
    return setmetatable({ffi.cast(ffi.typeof("void***"), interface)}, {__index = interface_mt})
end


local localize = create_interface("localize.dll", "Localize_001")
local convert_ansi_to_unicode = localize:get_function(15, "int", {"const char*", "wchar_t*", "int"})
local convert_unicode_to_ansi = localize:get_function(16, "int", {"const wchar_t*", "char*", "int"})
local find_safe = localize:get_function(12, "wchar_t*", {"const char*"})

-- set up surface metatable
local surface_mt   = {}
surface_mt.__index = surface_mt

surface_mt.isurface = create_interface("vguimatsurface.dll", "VGUI_Surface031")

surface_mt.fn_draw_set_color            = surface_mt.isurface:get_function(15, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_filled_rect          = surface_mt.isurface:get_function(16, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_outlined_rect        = surface_mt.isurface:get_function(18, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_line                 = surface_mt.isurface:get_function(19, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_set_text_font        = surface_mt.isurface:get_function(23, "void", {"unsigned long"})
surface_mt.fn_draw_set_text_color       = surface_mt.isurface:get_function(25, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_set_text_pos         = surface_mt.isurface:get_function(26, "void", {"int", "int"})
surface_mt.fn_draw_print_text           = surface_mt.isurface:get_function(28, "void", {"const wchar_t*", "int", "int" })

surface_mt.fn_create_font               = surface_mt.isurface:get_function(71, "unsigned int")
surface_mt.fn_set_font_glyph            = surface_mt.isurface:get_function(72, "void", {"unsigned long", "const char*", "int", "int", "int", "int", "unsigned long", "int", "int"})
surface_mt.fn_get_text_size             = surface_mt.isurface:get_function(79, "void", {"unsigned long", "const wchar_t*", "int&", "int&"})

function surface_mt:draw_set_color(r, g, b, a)
    self.fn_draw_set_color(r, g, b, a)
end

function surface_mt:draw_filled_rect_fade(x0, y0, x1, y1, alpha0, alpha1, horizontal)
    self.fn_draw_filled_rect_fade(x0, y0, x1, y1, alpha0, alpha1, horizontal)
end

function surface_mt:draw_set_text_font(font)
    self.fn_draw_set_text_font(font)
end

function surface_mt:draw_set_text_color(r, g, b, a)
    self.fn_draw_set_text_color(r, g, b, a)
end

function surface_mt:draw_set_text_pos(x, y)
    self.fn_draw_set_text_pos(x, y)
end


function surface_mt:draw_print_text(text, localized)
    if localized then
        local char_buffer = ffi.new('char[1024]')
        convert_unicode_to_ansi(text, char_buffer, 1024)
        local test = ffi.string(char_buffer)
        self.fn_draw_print_text(text, test:len(), 0)
    else
        local wide_buffer = ffi.new('wchar_t[1024]')
        convert_ansi_to_unicode(text, wide_buffer, 1024)
        self.fn_draw_print_text(wide_buffer, text:len(), 0)
    end
end

function surface_mt:create_font()
    return(self.fn_create_font())
end
function surface_mt:set_font_glyph(font, font_name, tall, weight, flags)
    local x = 0
    if type(flags) == "number" then
        x = flags
    elseif type(flags) == "table" then
        for i=1, #flags do
            x = x + flags[i]
        end
    end
    self.fn_set_font_glyph(font, font_name, tall, weight, 0, 0, bit.bor(x), 0, 0)
end

function surface_mt:get_text_size(font, text)
    local wide_buffer = ffi.new('wchar_t[1024]')
    local int_ptr = ffi.typeof("int[1]")
    local wide_ptr = int_ptr() local tall_ptr = int_ptr()

    convert_ansi_to_unicode(text, wide_buffer, 1024)
    self.fn_get_text_size(font, wide_buffer, wide_ptr, tall_ptr)
    local wide = tonumber(ffi.cast("int", wide_ptr[0]))
    local tall = tonumber(ffi.cast("int", tall_ptr[0]))
    return wide, tall
end
function renderer.create_font(windows_font_name, tall, weight, flags)
    local font = surface_mt:create_font()
    if type(flags) == "nil" then
        flags = 0
    end
    surface_mt:set_font_glyph(font, windows_font_name, tall, weight, flags)
    return font
end

function renderer.localize_string(text)
    local localized_string = find_safe(text)
    local char_buffer = ffi.new('char[1024]')
    convert_unicode_to_ansi(localized_string, char_buffer, 1024)
    return ffi.string(char_buffer)
end

function renderer.draw_text(x, y, r, g, b, a, font, text)
    surface_mt:draw_set_text_pos(x, y)
    surface_mt:draw_set_text_font(font)
    surface_mt:draw_set_text_color(r, g, b, a)
    surface_mt:draw_print_text(tostring(text), false)
end

function renderer.draw_localized_text(x, y, r, g, b, a, font, text)
    surface_mt:draw_set_text_pos(x, y)
    surface_mt:draw_set_text_font(font)
    surface_mt:draw_set_text_color(r, g, b, a)

    local localized_string = find_safe(text)

    surface_mt:draw_print_text(localized_string, true)
end

function renderer.draw_line(x0, y0, x1, y1, r, g, b, a)
    surface_mt:draw_set_color(r, g, b, a)
    surface_mt:draw_line(x0, y0, x1, y1)
end

function renderer.test_font(x, y, r, g, b, a, font, string)
    local _, height_offset = surface_mt:get_text_size(font, "a b c d e f g h i j k l m n o p q r s t u v w x y z")

    renderer.draw_text(x, y, r, g, b, a, font, string)
end

function renderer.get_text_size(font, text)
    return surface_mt:get_text_size(font, text)
end

-- gamesense renderer END

-- VMT HOOK START
local function copy(dst, src, len)
    return ffi.copy(ffi.cast('void*', dst), ffi.cast('const void*', src), len)
end

local function VirtualProtect(lpAddress, dwSize, flNewProtect, lpflOldProtect)
    return ffi.C.VirtualProtect(ffi.cast('void*', lpAddress), dwSize, flNewProtect, lpflOldProtect)
end

local function VirtualAlloc(lpAddress, dwSize, flAllocationType, flProtect, blFree)
    local alloc = ffi.C.VirtualAlloc(lpAddress, dwSize, flAllocationType, flProtect)
    if blFree then
        table.insert(buff.free, function()
            ffi.C.VirtualFree(alloc, 0, 0x8000)
        end)
    end
    return ffi.cast('intptr_t', alloc)
end
function vmt_hook.new(vt)
    local new_hook = {}
    local org_func = {}
    local old_prot = ffi.new('unsigned long[1]')
    local virtual_table = ffi.cast('intptr_t**', vt)[0]
    new_hook.this = virtual_table
    new_hook.hookMethod = function(cast, func, method)
        org_func[method] = virtual_table[method]
        VirtualProtect(virtual_table + method, 4, 0x4, old_prot)
        virtual_table[method] = ffi.cast('intptr_t', ffi.cast(cast, func))
        VirtualProtect(virtual_table + method, 4, old_prot[0], old_prot)
        return ffi.cast(cast, org_func[method])
    end
    new_hook.unHookMethod = function(method)
        VirtualProtect(virtual_table + method, 4, 0x4, old_prot)
        -- virtual_table[method] = org_func[method]
        local alloc_addr = VirtualAlloc(nil, 5, 0x1000, 0x40, false)
        local trampoline_bytes = ffi.new('uint8_t[?]', 5, 0x90)
        trampoline_bytes[0] = 0xE9
        ffi.cast('int32_t*', trampoline_bytes + 1)[0] = org_func[method] - tonumber(alloc_addr) - 5
        copy(alloc_addr, trampoline_bytes, 5)
        virtual_table[method] = ffi.cast('intptr_t', alloc_addr)
        VirtualProtect(virtual_table + method, 4, old_prot[0], old_prot)
        org_func[method] = nil
    end
    new_hook.unHookAll = function()
        for method, func in pairs(org_func) do
            new_hook.unHookMethod(method)
        end
    end
    table.insert(vmt_hook.hooks, new_hook.unHookAll)
    return new_hook
end
-- VMT HOOK END
local orig = nil
local VGUI_Panel009 = vmt_hook.new(target)

local font = renderer.create_font("Small Fonts", 8, 350, {0x10, 0x200}) -- Args (FontName, FontSize, FontWeight, Flags)
local screen_size = EngineClient.GetScreenSize()

function on_draw()

    local center = {screen_size.x/ 2, screen_size.y/ 2}


    local inverter_state = AntiAim.GetInverterState()
    local charge = Exploits.GetCharge()

    if pulsate_alpha:GetBool() then
        alpha = math.min(math.floor(math.sin((GlobalVars.curtime) * 3) * 180 + 200), 255)
    else
        alpha = 255
    end


    if not EngineClient:IsConnected() then
        return
    end

    if not enable_visuals:GetBool() then return end


    if inverter_state == false then
        desync = "R"
    elseif inverter_state == true then
        desync = "L"
    else
        desync = "B"
    end

    if manual_aa_side == "Left" then
        manual_aa_side = "LEFT"
    elseif manual_aa_side == "Right" then
        manual_aa_side = "RIGHT"
    elseif manual_aa_side == "Freestanding" then
        manual_aa_side = "FREESTANDING"
    end

    if (indicator_type:GetInt() == 0) then


        renderer.draw_text(center[1], center[2] + 40, 255, 255, 255, 255, font, "XOXA ")
        renderer.draw_text(center[1] + 21, center[2] + 40 , 106, 121, 186, alpha, font, "SYNC")


    if manual_aa == true then
        renderer.draw_text(center[1], center[2] + 50 , 200, 100, 100, 255, font, "YAW:")
        renderer.draw_text(center[1] + 19, center[2] + 50 , 130, 140, 200, 255, font, manual_aa_side)
    else
        renderer.draw_text(center[1], center[2] + 50 , 200, 100, 100, 255, font, "FAKE YAW:")
        renderer.draw_text(center[1] + 38, center[2] + 50 , 130, 140, 200, 255, font, desync)
    end

    if doubletap == true then
        renderer.draw_text(center[1], center[2] + 60, 185 - 35 * charge, 6 + 230 * charge, 0, 255, font, "DT")
    else
        renderer.draw_text(center[1], center[2] + 60, 155, 155, 155, 155, font, "DT")
    end

    if hideshots == true then
        renderer.draw_text(center[1] + 11, center[2] + 60, 255, 255, 255, 255, font, "HS")
    else
        renderer.draw_text(center[1] + 11, center[2] + 60, 155, 155, 155, 155, font, "HS")
    end

    if indicators:GetBool(1) then
    if min_dmg == true then
        renderer.draw_text(center[1], center[2] + 70, 255, 255, 255, 255, font, "DMG: ")
        renderer.draw_text(center[1] + 20, center[2] + 70, 255, 255, 255, 255, font, min_dmg_dmg)
    end
    end

    if indicators:GetBool(2) then
    if bodyaim == true then
        renderer.draw_text(center[1] + 23, center[2] + 60, 255, 255, 255, 255, font, "BAIM")
    end
    end

    if indicators:GetBool(3) then
    if safepoint == true and bodyaim == true and indicators:GetBool(2) then
        renderer.draw_text(center[1] + 43, center[2] + 60, 255, 255, 255, 255, font, "SAFE")
    elseif safepoint == true then
        renderer.draw_text(center[1] + 23, center[2] + 60, 255, 255, 255, 255, font, "SAFE")
    end
    end

end

end



function painttraverse_hk(one, two, three, four)
    local panel = two -- for some reason i had to do this, no idea why tho
    local panel_name = ffi.string(get_panel_name(one, panel))
    if(panel_name == "FocusOverlayPanel") then -- You can change this
        on_draw()
    end
    orig(one, two, three, four)
end
orig = VGUI_Panel009.hookMethod("void(__thiscall*)(void*, unsigned int, bool, bool)", painttraverse_hk, 41)

Cheat.RegisterCallback("destroy", function()
    for i, unHookFunc in ipairs(vmt_hook.hooks) do
        unHookFunc() -- unload all hooks
    end
end)


local last_pitch = ref_pitch:GetInt()
local last_yaw = ref_yaw:GetInt()

local was_in_use = false

local function legit_aa(cmd)
    if bit.band(cmd.buttons, bit.lshift(1,5)) ~= 0 and legitaa:GetBool() then
        cmd.buttons = bit.band(cmd.buttons, bit.bnot(bit.lshift(1,5)))
        was_in_use = true
    else
        was_in_use = false
    end
end


local function get_velocity(player)
    x = player:GetProp("DT_BasePlayer", "m_vecVelocity[0]")
    y = player:GetProp("DT_BasePlayer", "m_vecVelocity[1]")
    z = player:GetProp("DT_BasePlayer", "m_vecVelocity[2]")
    if x == nil then return end
    return math.sqrt(x*x + y*y + z*z)
end


local antiaim_stuff = {
    limit = 0,
    yaw = 0,
    lby = 0,
    jitter = false,
}

local function condition(entity)
    local speed = math.floor(get_velocity(entity))
    local duck_amount = entity:GetProp("DT_BasePlayer", "m_flDuckAmount")
    local m_fFlags = entity:GetProp("DT_BasePlayer", "m_fFlags")
    --standing
    if (speed <= 2) then
        return 1
    end
    --slowwalking
    if speed <= 100 and speed > 2 then
        return 2
    end
    --running
    if speed > 100 then
        return 3
    end
    --ducking
    if duck_amount == 1 then
        return 4
    end
    return false
end


local function vec_distance(vec_one, vec_two)

    local delta_x, delta_y, delta_z = vec_one.x - vec_two.x, vec_one.y - vec_two.y

    return math.sqrt(delta_x * delta_x + delta_y * delta_y)

end

local function get_closest_enemy()
    local best_dist = 380.0
    local best_enemy = nil
    local me = EntityList.GetLocalPlayer()
    local local_origin = me:GetProp("DT_BaseEntity", "m_vecOrigin")
    local local_screen_orig = Render.ScreenPosition(local_origin)
    local screen = EngineClient.GetScreenSize()

    for idx = 1, GlobalVars.maxClients + 1 do
        local ent = EntityList.GetClientEntity(idx)
        if ent and ent:IsPlayer() then
            local player = ent:GetPlayer()
            local health = player:GetProp("DT_BasePlayer", "m_iHealth")

            if not player:IsTeamMate() and health > 0 and not player:IsDormant() then
                local origin = ent:GetProp("DT_BaseEntity", "m_vecOrigin")
                local screen_orig = Render.ScreenPosition(origin)
                local temp_dist = vec_distance(Vector2.new(screen.x / 2, screen.y / 2), screen_orig)

                if(temp_dist < best_dist) then
                    best_dist = temp_dist
                    best_enemy = ent
                end
            end
        end
    end

    return best_enemy
end


local lines = {}
local results = {}

local function impacts_events(event)
    if event:GetName() == "bullet_impact" and event:GetInt("userid") == EntityList.GetLocalPlayer():GetPlayerInfo().userId then
        local me = EntityList.GetLocalPlayer()
        if me then me = me:GetPlayer() else return end
        local position = me:GetEyePosition()
        local destination = Vector.new(event:GetFloat("x"), event:GetFloat("y"), event:GetFloat("z"))
        table.insert(lines, {pos = position, destination = destination, time = 250, curtime = GlobalVars.curtime})
    end

    if event:GetName() == "player_hurt" then
        if event:GetInt("attacker") == EntityList.GetLocalPlayer():GetPlayerInfo().userId then
            for k,v in pairs(lines) do
                if v.curtime == GlobalVars.curtime then
                    table.insert(results, lines[k])
                    table.remove(lines, k)
                end
            end
        end
    end
end


local miss_counter = 0
local shot_time = 0

local function antibrute(event)

      if event:GetName() == "weapon_fire" then --Weapon Fire event later we run FOV check so we can make sure the bullet is on our direction!
        local user_id = event:GetInt("userid", -1)
        local user = EntityList.GetPlayerForUserID(user_id) --Get Enemy Entity
        local me = EntityList.GetLocalPlayer() --Get Local Entity
        local player = me:GetPlayer()
        local health = player:GetProp("DT_BasePlayer", "m_iHealth")

        if(health > 0) then -- if our local player is alive we run the AntiBrute Logic!

            local closest_enemy = get_closest_enemy() --Get Closest enemy based on distance
            if(closest_enemy ~= nil and user:EntIndex() == closest_enemy:EntIndex()) then
              miss_counter = miss_counter + 1 --Basic so we calculate missed shots of enemy also some checks so if we get hit don't run the code!
        shot_time = GlobalVars.curtime
            end
        end
    end
end




local function on_createmove(cmd)

    local me = EntityList.GetLocalPlayer()


-- RAGE


if enable_rage:GetBool() then

    if enable_dt:GetBool() then

if dt_mode:GetBool(1) then
    Exploits.OverrideDoubleTapSpeed(14)
elseif dt_mode:GetBool(2) then
    Exploits.OverrideDoubleTapSpeed(15)
end

if disable_correction:GetBool() then
    CVar.FindVar("cl_clock_correction"):SetInt(0)
    CVar.FindVar("cl_clock_correction_adjustment_max_amount"):SetInt(350)
else
    CVar.FindVar("cl_clock_correction"):SetInt(1)
end

end


end
-- end rage


-- MISC

if enable_misc:GetBool() then


if leg_fucker:GetBool() then
    local legs_int = Utils.RandomInt(0, 10)
    if legs_int < 5 then
        leg_move:SetInt(2)
    end
    if legs_int > 5 then
        leg_move:SetInt(1)
    end
end




end
-- end misc

-- AA


if enable_antiaim:GetBool() then 


    if disable_warmup:GetBool() then
        if (EntityList.GetGameRules():GetProp("m_bHasMatchStarted") == false) then
            ref_anti_aim_enable:SetBool(false)
        else
            ref_anti_aim_enable:SetBool(true)
        end
        end


if was_in_use then
    if not FakeLag.Choking() then
        ref_yaw:SetInt(0)
        ref_pitch:SetInt(0)
        ref_left_limit:SetInt(60)
        ref_right_limit:SetInt(60)
    end

    return
end

if Cheat.IsKeyDown(0x20) then

    local lby_int = Utils.RandomInt(0, 10)
        if lby_int < 5 then
            ref_inverter:SetBool(true)
            AntiAim.OverrideLBYOffset(58)
        end
        if lby_int > 5 then
            AntiAim.OverrideLBYOffset(-58)
            ref_inverter:SetBool(false)
        end
    return
end

if (aa_modes:GetInt() == 1) then
    ref_lby_mode:SetInt(1)
    ref_fake_options:SetBool(1, true)
    ref_desync_on_shot:SetBool(1, true)
    AntiAim.OverrideLimit(58)
elseif (aa_modes:GetInt() == 2) then
    ref_lby_mode:SetInt(1)
    ref_fake_options:SetBool(1, true)
    -- ref_fake_options:SetBool(2, true)
    ref_desync_on_shot:SetBool(3, true)
    AntiAim.OverrideLimit(58)
end


if (freestand_type:GetInt() == 0) then
    ref_freestand_desync:SetInt(1)
elseif (freestand_type:GetInt() == 1) then
    ref_freestand_desync:SetInt(2)
end

if ref_slowwalk:GetBool() and low_delta_slow:GetBool() then
    ref_left_limit:SetInt(25)
    ref_right_limit:SetInt(25)
    AntiAim.OverrideLimit(25)

    return

end


if me == nil then return end

        local aa_type = aa_modes:GetInt()

        local local_m_lifeState = me:GetProp("DT_BasePlayer", "m_lifeState")
        if local_m_lifestate then return end
            local cond = condition(me)                   --check condition for local.
            local inverter = AntiAim.GetInverterState()
            if shot_time + 2 > GlobalVars.curtime then
                if anti_brute:GetInt() == 1 then
                     if (miss_counter % 2 == 0) then --Logic 1
                        AntiAim.OverrideLimit(60.0)
                        AntiAim.OverrideYawOffset(4.0)
                        AntiAim.OverrideInverter(true)

                    else if (miss_counter % 2 == 1) then --Logic 2
                        AntiAim.OverrideInverter(false)
                        AntiAim.OverrideLimit(45.0)
                    end
                end
                end
                if anti_brute:GetInt() == 2 then
                     if (miss_counter % 3 == 0) then --Logic 1
                        AntiAim.OverrideLimit(45.0)
                        AntiAim.OverrideInverter(false)

                    else if (miss_counter % 3 == 1) then --Logic 2
                        AntiAim.OverrideLimit(15.0)
                        AntiAim.OverrideInverter(false)
                        AntiAim.OverrideYawOffset(8.0)

                    else if (miss_counter % 3 == 2) then --Logic 3
                        AntiAim.OverrideLimit(60.0)
                        AntiAim.OverrideInverter(true)
                        AntiAim.OverrideYawOffset(8.0)
                        end
                    end
                end
            end
            -- else



    end



end
-- end aa

end







Cheat.RegisterCallback("createmove", function(cmd)
    local me = EntityList:GetLocalPlayer()
    local weap = me:GetPlayer():GetActiveWeapon()
    if not weap then return end
    if was_in_use then
        if not in_bomb_site then
            cmd.buttons = bit.bor(cmd.buttons, bit.lshift(1,5))
        end
        was_in_use = false
        ref_yaw:SetInt(last_yaw)
        ref_pitch:SetInt(last_pitch)
    end
end)



local hstable = {
    "1 H$",
    "morre"
}

local function get_hstable()
    return hstable[Utils.RandomInt(1, #hstable)]:gsub('\"', '')
end

local baimtable = {
    "iq",
    "f12",
    "morre"
}

local function get_baimtable()
    return baimtable[Utils.RandomInt(1, #baimtable)]:gsub('\"', '')
end

local other = {
    knife = '2 facadas 1 pulseira',
    hegrenade = 'Senta',
    inferno = 'queima judeu',
    taser = 'eletrocutado',
}

buybot_delay2 = GlobalVars.curtime + 100000 --1 mill sec to make sure it only triggers 1 time

local function trashtalk_event(event)

    -- TRASHTALK
    if event:GetName() ~= "player_death" then return end

    me = EntityList.GetLocalPlayer()
    victim = EntityList.GetPlayerForUserID(event:GetInt("userid"))
    attacker = EntityList.GetPlayerForUserID(event:GetInt("attacker"))

    weapon_used = event:GetString("weapon", "unknown")

    is_headshot = event:GetBool("headshot", false)


    if victim == attacker or attacker ~= me then return end


    buybot_delay2 = GlobalVars.curtime + 2 --delay time (in sec)
    -- if trashtalk:GetBool() then

    --     if is_headshot then
    --         EngineClient.ExecuteClientCmd('say "' .. get_hstable() .. '"')
    --     elseif not is_headshot and not other[weapon_used] then
    --         EngineClient.ExecuteClientCmd('say "' .. get_baimtable() .. '"')
    --     else
    --         EngineClient.ExecuteClientCmd('say "' .. other[weapon_used] .. '"')
    --     end
    
    -- end
 

-- TRASHTALK

end



function buybot_draw2()
    if buybot_delay2 < GlobalVars.curtime then
 
        if is_headshot then
            EngineClient.ExecuteClientCmd('say "' .. get_hstable() .. '"')
        elseif not is_headshot and not other[weapon_used] then
            EngineClient.ExecuteClientCmd('say "' .. get_baimtable() .. '"')
        else
            EngineClient.ExecuteClientCmd('say "' .. other[weapon_used] .. '"')
        end
 
      buybot_delay2 = GlobalVars.curtime + 1000000 --1 mill sec to make sure it only triggers 1 time
    end
end 

verdana = Render.InitFont("Verdana", 12, {'b'})

local function indicators_draw()

    local indicator_color = visual_color:GetColor()
    local inverter_state = AntiAim.GetInverterState()
    local screen = EngineClient:GetScreenSize()

    if not EngineClient:IsConnected() then
        return
    end

    if (indicator_type:GetInt() == 1) then

      
    if inverter_state == true then
    Render.Text("XOXA", Vector2.new(screen.x / 2 - 17, screen.y / 2 + 20), indicator_color, 12, verdana, false, true)
    Render.Text("SYNC", Vector2.new(screen.x / 2 + 17, screen.y / 2 + 20), Color.new(1, 1, 1, 1), 12, verdana, false, true)
    else
    Render.Text("XOXA", Vector2.new(screen.x / 2 - 17, screen.y / 2 + 20), Color.new(1, 1, 1, 1), 12, verdana, false, true)
    Render.Text("SYNC", Vector2.new(screen.x / 2 + 17, screen.y / 2 + 20), indicator_color, 12, verdana, false, true)
    end


    if doubletap then
        Render.Text("double tap", Vector2.new(screen.x / 2, screen.y / 2 + 30), indicator_color, 11, verdana, false, true)
    else
        Render.Text("double tap", Vector2.new(screen.x / 2, screen.y / 2 + 30), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
    end

    if hideshots then
        Render.Text("hide shots", Vector2.new(screen.x / 2, screen.y / 2 + 40), indicator_color, 11, verdana, false, true)
    else
        Render.Text("hide shots", Vector2.new(screen.x / 2, screen.y / 2 + 40), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
    end



    if indicators:GetBool(1) then
        body_size = 60
    else
        body_size = 50
    end

    if indicators:GetBool(1) and indicators:GetBool(2) then
        sp_size = 70
    elseif indicators:GetBool(1) or indicators:GetBool(2) then
        sp_size = 60
    else
        sp_size = 50
    end

    if indicators:GetBool(1) then
        if min_dmg then
            Render.Text("min dmg", Vector2.new(screen.x / 2, screen.y / 2 + 50), indicator_color, 11, verdana, false, true)
        else
            Render.Text("min dmg", Vector2.new(screen.x / 2, screen.y / 2 + 50), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
        end
    end

    if indicators:GetBool(2) then
        if bodyaim then
            Render.Text("body aim", Vector2.new(screen.x / 2, screen.y / 2 + body_size), indicator_color, 11, verdana, false, true)
        else
            Render.Text("body aim", Vector2.new(screen.x / 2, screen.y / 2 + body_size), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
        end
    end


    if indicators:GetBool(3) then
        if safepoint then
            Render.Text("safe point", Vector2.new(screen.x / 2, screen.y / 2 + sp_size), indicator_color, 11, verdana, false, true)
        else
            Render.Text("safe point", Vector2.new(screen.x / 2, screen.y / 2 + sp_size), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
        end
    end

    end


    local lpx = Vector2.new(screen.x / 2 - 42, screen.y / 2 + 9)
    local lpy = Vector2.new(screen.x / 2 - 42, screen.y / 2 - 9)
    local lpz = Vector2.new(screen.x / 2 - 54, screen.y / 2)

    local rpx = Vector2.new(screen.x / 2 + 42, screen.y / 2 + 9)
    local rpy = Vector2.new(screen.x / 2 + 42, screen.y / 2 - 9)
    local rpz = Vector2.new(screen.x / 2 + 55, screen.y / 2)

    local inactive = Color.new(20 / 255, 20 / 255, 20 / 255, 0.5) -- RGB: 20, 20, 20, 128

    if teamskeet_arrows:GetBool() then

        if manual_aa_side == "Left" then
            Render.PolyFilled(second_color:GetColor(), lpx, lpy, lpz)
        else
            Render.PolyFilled(inactive, lpx, lpy, lpz)
        end
        
        if manual_aa_side == "Right" then
            Render.PolyFilled(second_color:GetColor(), rpx, rpy, rpz)
        else
            Render.PolyFilled(inactive, rpx, rpy, rpz)
        end

        if inverter_state == true then
            Render.BoxFilled(Vector2.new(screen.x / 2 - 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 - 38 , screen.y / 2 + 9), visual_color:GetColor())
        else
            Render.BoxFilled(Vector2.new(screen.x / 2 - 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 - 38, screen.y / 2 + 9), inactive)
        end

        if inverter_state == false then
            Render.BoxFilled(Vector2.new(screen.x / 2 + 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 + 38, screen.y / 2 + 9), visual_color:GetColor())
        else
            Render.BoxFilled(Vector2.new(screen.x / 2 + 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 + 38, screen.y / 2 + 9), inactive)
        end

    end

end



MenuVisibility = function()
    local switch_antiaim = enable_antiaim:GetBool();
    local switch_rage = enable_rage:GetBool();
    local switch_visuals = enable_visuals:GetBool();
    local switch_misc = enable_misc:GetBool();

    -- custom
    -- local da_switch = dormant_aimbot:GetBool()
    local dt_switch = enable_dt:GetBool()
    local arrow_switch = teamskeet_arrows:GetBool()

    legitaa:SetVisible(switch_antiaim);
    aa_modes:SetVisible(switch_antiaim);
    freestand_type:SetVisible(switch_antiaim);
    anti_brute:SetVisible(switch_antiaim);
    low_delta_slow:SetVisible(switch_antiaim);
    disable_warmup:SetVisible(switch_antiaim)

    -- dormant_aimbot:SetVisible(switch_rage);
    -- da_dmg:SetVisible(da_switch and switch_rage);
    enable_dt:SetVisible(switch_rage);
    dt_mode:SetVisible(dt_switch and switch_rage);
    disable_correction:SetVisible(dt_switch and switch_rage);
    anti_defensive:SetVisible(switch_rage)
    
  

    -- visual_color:SetVisible(switch_visuals);
    indicators:SetVisible(switch_visuals);
    indicator_type:SetVisible(switch_visuals);
    visual_color:SetVisible(switch_visuals);
    teamskeet_arrows:SetVisible(switch_visuals);
    second_color:SetVisible(switch_visuals and arrow_switch);
    pulsate_alpha:SetVisible(switch_visuals)

    leg_fucker:SetVisible(switch_misc);
    trashtalk:SetVisible(switch_misc)


end

enable_antiaim:RegisterCallback(MenuVisibility);
enable_rage:RegisterCallback(MenuVisibility);
enable_visuals:RegisterCallback(MenuVisibility);
enable_misc:RegisterCallback(MenuVisibility);

-- custom
-- dormant_aimbot:RegisterCallback(MenuVisibility);

enable_dt:RegisterCallback(MenuVisibility);
teamskeet_arrows:RegisterCallback(MenuVisibility)

MenuVisibility();

Cheat.AddNotify("xoxasync", "Welcome, " .. username .. " ")


local function events(event)

    trashtalk_event(event)
    antibrute(event)
    impacts_events(event)

end

Cheat.RegisterCallback("events", events)


Cheat.RegisterCallback("prediction", function()
on_createmove()
end)

Cheat.RegisterCallback("pre_prediction", function(cmd)
    legit_aa(cmd)
end)

Cheat.RegisterCallback("draw", function()
    handle_binds()
    indicators_draw()
end)

Cheat.RegisterCallback("frame_stage", function()
    buybot_draw2()
  end)
 
kitty.
Пользователь
Статус
Оффлайн
Регистрация
17 Окт 2021
Сообщения
282
Реакции[?]
111
Поинты[?]
17K
это че за пиздец, зачем чел ребилднул сюрфейс рендер в луашке...
 
Участник
Статус
Оффлайн
Регистрация
29 Дек 2019
Сообщения
381
Реакции[?]
167
Поинты[?]
2K
Код:
username = Cheat.GetCheatUserName()

local ffi = require("ffi")
local shell = ffi.load("Shell32.dll")

ffi.cdef[[
    int ShellExecuteA(void* hwnd, const char* lpOperation, const char* lpFile, const char* lpParameters, const char* lpDirectory, int nShowCmd);
]]

-- REFERENCES
local leg_move = Menu.FindVar("Aimbot", "Anti Aim", "Misc", "Leg Movement")
local ref_yaw = Menu.FindVar("Aimbot", "Anti Aim", "Main", "Yaw Base")
local ref_pitch = Menu.FindVar("Aimbot", "Anti Aim", "Main", "Pitch")
local ref_slowwalk = Menu.FindVar("Aimbot", "Anti Aim", "Misc", "Slow Walk")
local ref_left_limit = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Left Limit")
local ref_right_limit = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Right Limit")
local ref_fake_options = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Fake Options")
local ref_lby_mode = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "LBY Mode")
local ref_freestand_desync = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Freestanding Desync")
local ref_desync_on_shot = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Desync On Shot")
local ref_anti_aim_enable = Menu.FindVar("Aimbot", "Anti Aim", "Main", "Enable Anti Aim")
local ref_inverter = Menu.FindVar("Aimbot", "Anti Aim", "Fake Angle", "Inverter")



-- MENU ITEMS
Menu.Text("xoxasync", "Welcome to xoxasync " .. username .. "!")
Menu.Button("xoxasync", "Discord", "Join our discord", function()
shell.ShellExecuteA(nil, "open", "https://discord.gg/7tMGemzj84", nil, nil, 0)
end)

--AA
local enable_antiaim = Menu.Switch("Anti-Aim", "Enable", false, "Enable anti-aim")
local aa_modes = Menu.Combo("Anti-Aim", "Anti-aim mode", {"None", "Aggresive", "Dynamic"}, 0, "Anti-aim modes")
local freestand_type = Menu.Combo("Anti-Aim", "Freestanding type", {"Normal", "Xoxaverse"}, 0, "Freestanding modes")
-- local anti_brute = Menu.Switch("Anti-Aim", "Anti brute-force", false, "Change desync side on miss")
local anti_brute = Menu.Combo("Anti-Aim", "Anti Bruteforce", {"Off", "Normal", "Xoxa brute"}, 0, "")
local low_delta_slow = Menu.Switch("Anti-Aim", "Low delta on slow walk", false, "Low delta while slow-walking")
local legitaa = Menu.Switch("Anti-Aim", "Legit Anti Aim on use", false, "Legit AA while you hold E")
local disable_warmup = Menu.Switch("Anti-Aim", "Disable on warmup", false, "Disables AA on warmup")

-- RAGE
local enable_rage = Menu.Switch("Rage", "Enable", false, "Enable rage")
local enable_dt = Menu.Switch("Rage", "Doubletap", false, "Enables double tap modifier")
local dt_mode = Menu.Combo("Rage", "Doubletap modes", {"Fast", "xoxatap"}, 0, "Doubletap modes")
local disable_correction = Menu.Switch("Rage", "Disable Correction", false, "Disable clock correction")
-- local dormant_aimbot = Menu.Switch("Rage", "Dormant Aimbot", false, "Shoots the target while its dormant")
-- local da_dmg = Menu.SliderInt("Rage", "Dormant Damage", 1, 0, 100, "Dormant aimbot minimum damage")    
local anti_defensive = Menu.Button("Rage", "Anti Defensive", "Anti defensive double tap", function()
    EngineClient.ExecuteClientCmd("jointeam 1 1")

    CVar.FindVar("cl_lagcompensation"):SetInt(0)
    -- CVar.FindVar("cl_predict"):SetInt(0)
end)


-- VISUALS
local enable_visuals = Menu.Switch("Visuals", "Enable", false, "Enable visuals")
local indicator_type = Menu.Combo("Visuals", "Indicator type", {"Acatel", "Dynamic"}, 0, "Indicators type")
local pulsate_alpha = Menu.Switch("Visuals", "Pulsating indicator", false, "Pulsates 'sync' indicator")
local teamskeet_arrows = Menu.Switch("Visuals", "Anti aim arrows", false, "'Team sk33t' arrows")
local visual_color = Menu.ColorEdit("Visuals", "Color", Color.new(1.0, 1.0, 1.0, 1.0), "Indicator color")
local second_color = Menu.ColorEdit("Visuals", "Second Color", Color.new(1.0, 1.0, 1.0, 1.0), "Second indicator color")
local indicators = Menu.MultiCombo("Visuals", "Additional indicators", {"Min Damage", "Body Aim", "Safe Point"}, 0)

-- MISC
local enable_misc = Menu.Switch("Misc", "Enable", false, "Enable misc")
local leg_fucker = Menu.Switch("Misc", "Leg fucker", false, "Randomize leg movement")
local trashtalk = Menu.Switch("Misc", "Trastalk", false, "Trashtalks enemy when you kill")

Menu.Text("Updates", "Last update: 8th October")
Menu.Text("Updates", " - Improved everything")


local function handle_binds()
    local binds = Cheat.GetBinds()
    for i = 1, #binds do
        if binds[i]:GetName() == "Minimum Damage" and binds[i]:IsActive() then
        min_dmg = true
        min_dmg_dmg = binds[i]:GetValue()
        end
        if binds[i]:GetName() == "Minimum Damage" and not binds[i]:IsActive() then
            min_dmg = false
        end
   
        if binds[i]:GetName() == "Double Tap" and binds[i]:IsActive() then
        doubletap = true
        end
        if binds[i]:GetName() == "Double Tap" and not binds[i]:IsActive() then
        doubletap = false
        end
   
        if binds[i]:GetName() == "Hide Shots" and binds[i]:IsActive() then
        hideshots = true
        end
        if binds[i]:GetName() == "Hide Shots" and not binds[i]:IsActive() then
        hideshots = false
        end
   
        if binds[i]:GetName() == "Auto Peek" and binds[i]:IsActive() then
        quickpeek = true
        end
        if binds[i]:GetName() == "Auto Peek" and not binds[i]:IsActive() then
        quickpeek = false
        end
   
        if binds[i]:GetName() == "Fake Duck" and binds[i]:IsActive() then
        fakeduck = true
        end
        if binds[i]:GetName() == "Fake Duck" and not binds[i]:IsActive() then
        fakeduck = false
        end

        if binds[i]:GetName() == "Body Aim" and binds[i]:IsActive() then
        bodyaim = true
        end
        if binds[i]:GetName() == "Body Aim" and not binds[i]:IsActive() then
        bodyaim = false
        end

        if binds[i]:GetName() == "Safe Points" and binds[i]:IsActive() then
        safepoint = true
        end
        if binds[i]:GetName() == "Safe Points" and not binds[i]:IsActive() then
        safepoint = false
        end
   
        if binds[i]:GetName() == "Yaw Base" and binds[i]:IsActive() then
        manual_aa = true
        manual_aa_side = binds[i]:GetValue()
        end
        if binds[i]:GetName() == "Yaw Base" and not binds[i]:IsActive() then
        manual_aa = false
        end

    end
end

local ffi = require("ffi")
local bit = require("bit")
local cast = ffi.cast
local unpack = table.unpack
local bor = bit.bor
local buff = {free = {}}
local vmt_hook = {hooks = {}}
local target = Utils.CreateInterface("vgui2.dll", "VGUI_Panel009")
local interface_type = ffi.typeof("void***")
-- gamesense renderer start
local renderer = {}


ffi.cdef[[
    int VirtualProtect(void* lpAddress, unsigned long dwSize, unsigned long flNewProtect, unsigned long* lpflOldProtect);
    void* VirtualAlloc(void* lpAddress, unsigned long dwSize, unsigned long  flAllocationType, unsigned long flProtect);
    int VirtualFree(void* lpAddress, unsigned long dwSize, unsigned long dwFreeType);
    typedef unsigned char wchar_t;
    typedef int(__thiscall* ConvertAnsiToUnicode_t)(void*, const char*, wchar_t*, int);
    typedef int(__thiscall* ConvertUnicodeToAnsi_t)(void*, const wchar_t*, char*, int);
    typedef wchar_t*(__thiscall* FindSafe_t)(void*, const char*);
    typedef void(__thiscall* draw_set_text_color_t)(void*, int, int, int, int);
    typedef void(__thiscall* draw_set_color_t)(void*, int, int, int, int);
    typedef void(__thiscall* draw_filled_rect_fade_t)(void*, int, int, int, int, unsigned int, unsigned int, bool);
    typedef void(__thiscall* draw_set_text_font_t)(void*, unsigned long);
    typedef void(__thiscall* get_text_size_t)(void*, unsigned long, const wchar_t*, int&, int&);
    typedef void(__thiscall* draw_set_text_pos_t)(void*, int, int);
    typedef void(__thiscall* draw_print_text_t)(void*, const wchar_t*, int, int);
    typedef void(__thiscall* set_font_glyph_t)(void*, unsigned long, const char*, int, int, int, int, unsigned long, int, int);
    typedef unsigned int(__thiscall* create_font_t)(void*);
]]

local get_panel_name_type = ffi.typeof("const char*(__thiscall*)(void*, uint32_t)")

local panel_interface = ffi.cast(interface_type, target) --
local panel_interface_vtbl = panel_interface[0] --
local get_panel_name_raw = panel_interface_vtbl[36] --
local get_panel_name = ffi.cast(get_panel_name_type, get_panel_name_raw)  -- credits to alphanine

local function uuid(len)
    local res, len = "", len or 32
    for i=1, len do
        res = res .. string.char(Utils.RandomInt(97, 122))
    end
    return res
end

local interface_mt = {}

function interface_mt.get_function(self, index, ret, args)
    local ct = uuid() .. "_t"

    args = args or {}
    if type(args) == "table" then
        table.insert(args, 1, "void*")
    else
        return error("args has to be of type table", 2)
    end
    local success, res = pcall(ffi.cdef, "typedef " .. ret .. " (__thiscall* " .. ct .. ")(" .. table.concat(args, ", ") .. ");")
    if not success then
        error("invalid typedef: " .. res, 2)
    end

    local interface = self[1]
    local success, func = pcall(ffi.cast, ct, interface[0][index])
    if not success then
        return error("failed to cast: " .. func, 2)
    end

    return function(...)
        local success, res = pcall(func, interface, ...)

        if not success then
            return error("call: " .. res, 2)
        end

        if ret == "const char*" then
            return res ~= nil and ffi.string(res) or nil
        end
        return res
    end
end

local function create_interface(dll, interface_name)
    local interface = (type(dll) == "string" and type(interface_name) == "string") and Utils.CreateInterface(dll, interface_name) or dll
    return setmetatable({ffi.cast(ffi.typeof("void***"), interface)}, {__index = interface_mt})
end


local localize = create_interface("localize.dll", "Localize_001")
local convert_ansi_to_unicode = localize:get_function(15, "int", {"const char*", "wchar_t*", "int"})
local convert_unicode_to_ansi = localize:get_function(16, "int", {"const wchar_t*", "char*", "int"})
local find_safe = localize:get_function(12, "wchar_t*", {"const char*"})

-- set up surface metatable
local surface_mt   = {}
surface_mt.__index = surface_mt

surface_mt.isurface = create_interface("vguimatsurface.dll", "VGUI_Surface031")

surface_mt.fn_draw_set_color            = surface_mt.isurface:get_function(15, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_filled_rect          = surface_mt.isurface:get_function(16, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_outlined_rect        = surface_mt.isurface:get_function(18, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_line                 = surface_mt.isurface:get_function(19, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_set_text_font        = surface_mt.isurface:get_function(23, "void", {"unsigned long"})
surface_mt.fn_draw_set_text_color       = surface_mt.isurface:get_function(25, "void", {"int", "int", "int", "int"})
surface_mt.fn_draw_set_text_pos         = surface_mt.isurface:get_function(26, "void", {"int", "int"})
surface_mt.fn_draw_print_text           = surface_mt.isurface:get_function(28, "void", {"const wchar_t*", "int", "int" })

surface_mt.fn_create_font               = surface_mt.isurface:get_function(71, "unsigned int")
surface_mt.fn_set_font_glyph            = surface_mt.isurface:get_function(72, "void", {"unsigned long", "const char*", "int", "int", "int", "int", "unsigned long", "int", "int"})
surface_mt.fn_get_text_size             = surface_mt.isurface:get_function(79, "void", {"unsigned long", "const wchar_t*", "int&", "int&"})

function surface_mt:draw_set_color(r, g, b, a)
    self.fn_draw_set_color(r, g, b, a)
end

function surface_mt:draw_filled_rect_fade(x0, y0, x1, y1, alpha0, alpha1, horizontal)
    self.fn_draw_filled_rect_fade(x0, y0, x1, y1, alpha0, alpha1, horizontal)
end

function surface_mt:draw_set_text_font(font)
    self.fn_draw_set_text_font(font)
end

function surface_mt:draw_set_text_color(r, g, b, a)
    self.fn_draw_set_text_color(r, g, b, a)
end

function surface_mt:draw_set_text_pos(x, y)
    self.fn_draw_set_text_pos(x, y)
end


function surface_mt:draw_print_text(text, localized)
    if localized then
        local char_buffer = ffi.new('char[1024]')
        convert_unicode_to_ansi(text, char_buffer, 1024)
        local test = ffi.string(char_buffer)
        self.fn_draw_print_text(text, test:len(), 0)
    else
        local wide_buffer = ffi.new('wchar_t[1024]')
        convert_ansi_to_unicode(text, wide_buffer, 1024)
        self.fn_draw_print_text(wide_buffer, text:len(), 0)
    end
end

function surface_mt:create_font()
    return(self.fn_create_font())
end
function surface_mt:set_font_glyph(font, font_name, tall, weight, flags)
    local x = 0
    if type(flags) == "number" then
        x = flags
    elseif type(flags) == "table" then
        for i=1, #flags do
            x = x + flags[i]
        end
    end
    self.fn_set_font_glyph(font, font_name, tall, weight, 0, 0, bit.bor(x), 0, 0)
end

function surface_mt:get_text_size(font, text)
    local wide_buffer = ffi.new('wchar_t[1024]')
    local int_ptr = ffi.typeof("int[1]")
    local wide_ptr = int_ptr() local tall_ptr = int_ptr()

    convert_ansi_to_unicode(text, wide_buffer, 1024)
    self.fn_get_text_size(font, wide_buffer, wide_ptr, tall_ptr)
    local wide = tonumber(ffi.cast("int", wide_ptr[0]))
    local tall = tonumber(ffi.cast("int", tall_ptr[0]))
    return wide, tall
end
function renderer.create_font(windows_font_name, tall, weight, flags)
    local font = surface_mt:create_font()
    if type(flags) == "nil" then
        flags = 0
    end
    surface_mt:set_font_glyph(font, windows_font_name, tall, weight, flags)
    return font
end

function renderer.localize_string(text)
    local localized_string = find_safe(text)
    local char_buffer = ffi.new('char[1024]')
    convert_unicode_to_ansi(localized_string, char_buffer, 1024)
    return ffi.string(char_buffer)
end

function renderer.draw_text(x, y, r, g, b, a, font, text)
    surface_mt:draw_set_text_pos(x, y)
    surface_mt:draw_set_text_font(font)
    surface_mt:draw_set_text_color(r, g, b, a)
    surface_mt:draw_print_text(tostring(text), false)
end

function renderer.draw_localized_text(x, y, r, g, b, a, font, text)
    surface_mt:draw_set_text_pos(x, y)
    surface_mt:draw_set_text_font(font)
    surface_mt:draw_set_text_color(r, g, b, a)

    local localized_string = find_safe(text)

    surface_mt:draw_print_text(localized_string, true)
end

function renderer.draw_line(x0, y0, x1, y1, r, g, b, a)
    surface_mt:draw_set_color(r, g, b, a)
    surface_mt:draw_line(x0, y0, x1, y1)
end

function renderer.test_font(x, y, r, g, b, a, font, string)
    local _, height_offset = surface_mt:get_text_size(font, "a b c d e f g h i j k l m n o p q r s t u v w x y z")

    renderer.draw_text(x, y, r, g, b, a, font, string)
end

function renderer.get_text_size(font, text)
    return surface_mt:get_text_size(font, text)
end

-- gamesense renderer END

-- VMT HOOK START
local function copy(dst, src, len)
    return ffi.copy(ffi.cast('void*', dst), ffi.cast('const void*', src), len)
end

local function VirtualProtect(lpAddress, dwSize, flNewProtect, lpflOldProtect)
    return ffi.C.VirtualProtect(ffi.cast('void*', lpAddress), dwSize, flNewProtect, lpflOldProtect)
end

local function VirtualAlloc(lpAddress, dwSize, flAllocationType, flProtect, blFree)
    local alloc = ffi.C.VirtualAlloc(lpAddress, dwSize, flAllocationType, flProtect)
    if blFree then
        table.insert(buff.free, function()
            ffi.C.VirtualFree(alloc, 0, 0x8000)
        end)
    end
    return ffi.cast('intptr_t', alloc)
end
function vmt_hook.new(vt)
    local new_hook = {}
    local org_func = {}
    local old_prot = ffi.new('unsigned long[1]')
    local virtual_table = ffi.cast('intptr_t**', vt)[0]
    new_hook.this = virtual_table
    new_hook.hookMethod = function(cast, func, method)
        org_func[method] = virtual_table[method]
        VirtualProtect(virtual_table + method, 4, 0x4, old_prot)
        virtual_table[method] = ffi.cast('intptr_t', ffi.cast(cast, func))
        VirtualProtect(virtual_table + method, 4, old_prot[0], old_prot)
        return ffi.cast(cast, org_func[method])
    end
    new_hook.unHookMethod = function(method)
        VirtualProtect(virtual_table + method, 4, 0x4, old_prot)
        -- virtual_table[method] = org_func[method]
        local alloc_addr = VirtualAlloc(nil, 5, 0x1000, 0x40, false)
        local trampoline_bytes = ffi.new('uint8_t[?]', 5, 0x90)
        trampoline_bytes[0] = 0xE9
        ffi.cast('int32_t*', trampoline_bytes + 1)[0] = org_func[method] - tonumber(alloc_addr) - 5
        copy(alloc_addr, trampoline_bytes, 5)
        virtual_table[method] = ffi.cast('intptr_t', alloc_addr)
        VirtualProtect(virtual_table + method, 4, old_prot[0], old_prot)
        org_func[method] = nil
    end
    new_hook.unHookAll = function()
        for method, func in pairs(org_func) do
            new_hook.unHookMethod(method)
        end
    end
    table.insert(vmt_hook.hooks, new_hook.unHookAll)
    return new_hook
end
-- VMT HOOK END
local orig = nil
local VGUI_Panel009 = vmt_hook.new(target)

local font = renderer.create_font("Small Fonts", 8, 350, {0x10, 0x200}) -- Args (FontName, FontSize, FontWeight, Flags)
local screen_size = EngineClient.GetScreenSize()

function on_draw()

    local center = {screen_size.x/ 2, screen_size.y/ 2}


    local inverter_state = AntiAim.GetInverterState()
    local charge = Exploits.GetCharge()

    if pulsate_alpha:GetBool() then
        alpha = math.min(math.floor(math.sin((GlobalVars.curtime) * 3) * 180 + 200), 255)
    else
        alpha = 255
    end


    if not EngineClient:IsConnected() then
        return
    end

    if not enable_visuals:GetBool() then return end


    if inverter_state == false then
        desync = "R"
    elseif inverter_state == true then
        desync = "L"
    else
        desync = "B"
    end

    if manual_aa_side == "Left" then
        manual_aa_side = "LEFT"
    elseif manual_aa_side == "Right" then
        manual_aa_side = "RIGHT"
    elseif manual_aa_side == "Freestanding" then
        manual_aa_side = "FREESTANDING"
    end

    if (indicator_type:GetInt() == 0) then


        renderer.draw_text(center[1], center[2] + 40, 255, 255, 255, 255, font, "XOXA ")
        renderer.draw_text(center[1] + 21, center[2] + 40 , 106, 121, 186, alpha, font, "SYNC")


    if manual_aa == true then
        renderer.draw_text(center[1], center[2] + 50 , 200, 100, 100, 255, font, "YAW:")
        renderer.draw_text(center[1] + 19, center[2] + 50 , 130, 140, 200, 255, font, manual_aa_side)
    else
        renderer.draw_text(center[1], center[2] + 50 , 200, 100, 100, 255, font, "FAKE YAW:")
        renderer.draw_text(center[1] + 38, center[2] + 50 , 130, 140, 200, 255, font, desync)
    end

    if doubletap == true then
        renderer.draw_text(center[1], center[2] + 60, 185 - 35 * charge, 6 + 230 * charge, 0, 255, font, "DT")
    else
        renderer.draw_text(center[1], center[2] + 60, 155, 155, 155, 155, font, "DT")
    end

    if hideshots == true then
        renderer.draw_text(center[1] + 11, center[2] + 60, 255, 255, 255, 255, font, "HS")
    else
        renderer.draw_text(center[1] + 11, center[2] + 60, 155, 155, 155, 155, font, "HS")
    end

    if indicators:GetBool(1) then
    if min_dmg == true then
        renderer.draw_text(center[1], center[2] + 70, 255, 255, 255, 255, font, "DMG: ")
        renderer.draw_text(center[1] + 20, center[2] + 70, 255, 255, 255, 255, font, min_dmg_dmg)
    end
    end

    if indicators:GetBool(2) then
    if bodyaim == true then
        renderer.draw_text(center[1] + 23, center[2] + 60, 255, 255, 255, 255, font, "BAIM")
    end
    end

    if indicators:GetBool(3) then
    if safepoint == true and bodyaim == true and indicators:GetBool(2) then
        renderer.draw_text(center[1] + 43, center[2] + 60, 255, 255, 255, 255, font, "SAFE")
    elseif safepoint == true then
        renderer.draw_text(center[1] + 23, center[2] + 60, 255, 255, 255, 255, font, "SAFE")
    end
    end

end

end



function painttraverse_hk(one, two, three, four)
    local panel = two -- for some reason i had to do this, no idea why tho
    local panel_name = ffi.string(get_panel_name(one, panel))
    if(panel_name == "FocusOverlayPanel") then -- You can change this
        on_draw()
    end
    orig(one, two, three, four)
end
orig = VGUI_Panel009.hookMethod("void(__thiscall*)(void*, unsigned int, bool, bool)", painttraverse_hk, 41)

Cheat.RegisterCallback("destroy", function()
    for i, unHookFunc in ipairs(vmt_hook.hooks) do
        unHookFunc() -- unload all hooks
    end
end)


local last_pitch = ref_pitch:GetInt()
local last_yaw = ref_yaw:GetInt()

local was_in_use = false

local function legit_aa(cmd)
    if bit.band(cmd.buttons, bit.lshift(1,5)) ~= 0 and legitaa:GetBool() then
        cmd.buttons = bit.band(cmd.buttons, bit.bnot(bit.lshift(1,5)))
        was_in_use = true
    else
        was_in_use = false
    end
end


local function get_velocity(player)
    x = player:GetProp("DT_BasePlayer", "m_vecVelocity[0]")
    y = player:GetProp("DT_BasePlayer", "m_vecVelocity[1]")
    z = player:GetProp("DT_BasePlayer", "m_vecVelocity[2]")
    if x == nil then return end
    return math.sqrt(x*x + y*y + z*z)
end


local antiaim_stuff = {
    limit = 0,
    yaw = 0,
    lby = 0,
    jitter = false,
}

local function condition(entity)
    local speed = math.floor(get_velocity(entity))
    local duck_amount = entity:GetProp("DT_BasePlayer", "m_flDuckAmount")
    local m_fFlags = entity:GetProp("DT_BasePlayer", "m_fFlags")
    --standing
    if (speed <= 2) then
        return 1
    end
    --slowwalking
    if speed <= 100 and speed > 2 then
        return 2
    end
    --running
    if speed > 100 then
        return 3
    end
    --ducking
    if duck_amount == 1 then
        return 4
    end
    return false
end


local function vec_distance(vec_one, vec_two)

    local delta_x, delta_y, delta_z = vec_one.x - vec_two.x, vec_one.y - vec_two.y

    return math.sqrt(delta_x * delta_x + delta_y * delta_y)

end

local function get_closest_enemy()
    local best_dist = 380.0
    local best_enemy = nil
    local me = EntityList.GetLocalPlayer()
    local local_origin = me:GetProp("DT_BaseEntity", "m_vecOrigin")
    local local_screen_orig = Render.ScreenPosition(local_origin)
    local screen = EngineClient.GetScreenSize()

    for idx = 1, GlobalVars.maxClients + 1 do
        local ent = EntityList.GetClientEntity(idx)
        if ent and ent:IsPlayer() then
            local player = ent:GetPlayer()
            local health = player:GetProp("DT_BasePlayer", "m_iHealth")

            if not player:IsTeamMate() and health > 0 and not player:IsDormant() then
                local origin = ent:GetProp("DT_BaseEntity", "m_vecOrigin")
                local screen_orig = Render.ScreenPosition(origin)
                local temp_dist = vec_distance(Vector2.new(screen.x / 2, screen.y / 2), screen_orig)

                if(temp_dist < best_dist) then
                    best_dist = temp_dist
                    best_enemy = ent
                end
            end
        end
    end

    return best_enemy
end


local lines = {}
local results = {}

local function impacts_events(event)
    if event:GetName() == "bullet_impact" and event:GetInt("userid") == EntityList.GetLocalPlayer():GetPlayerInfo().userId then
        local me = EntityList.GetLocalPlayer()
        if me then me = me:GetPlayer() else return end
        local position = me:GetEyePosition()
        local destination = Vector.new(event:GetFloat("x"), event:GetFloat("y"), event:GetFloat("z"))
        table.insert(lines, {pos = position, destination = destination, time = 250, curtime = GlobalVars.curtime})
    end

    if event:GetName() == "player_hurt" then
        if event:GetInt("attacker") == EntityList.GetLocalPlayer():GetPlayerInfo().userId then
            for k,v in pairs(lines) do
                if v.curtime == GlobalVars.curtime then
                    table.insert(results, lines[k])
                    table.remove(lines, k)
                end
            end
        end
    end
end


local miss_counter = 0
local shot_time = 0

local function antibrute(event)

      if event:GetName() == "weapon_fire" then --Weapon Fire event later we run FOV check so we can make sure the bullet is on our direction!
        local user_id = event:GetInt("userid", -1)
        local user = EntityList.GetPlayerForUserID(user_id) --Get Enemy Entity
        local me = EntityList.GetLocalPlayer() --Get Local Entity
        local player = me:GetPlayer()
        local health = player:GetProp("DT_BasePlayer", "m_iHealth")

        if(health > 0) then -- if our local player is alive we run the AntiBrute Logic!

            local closest_enemy = get_closest_enemy() --Get Closest enemy based on distance
            if(closest_enemy ~= nil and user:EntIndex() == closest_enemy:EntIndex()) then
              miss_counter = miss_counter + 1 --Basic so we calculate missed shots of enemy also some checks so if we get hit don't run the code!
        shot_time = GlobalVars.curtime
            end
        end
    end
end




local function on_createmove(cmd)

    local me = EntityList.GetLocalPlayer()


-- RAGE


if enable_rage:GetBool() then

    if enable_dt:GetBool() then

if dt_mode:GetBool(1) then
    Exploits.OverrideDoubleTapSpeed(14)
elseif dt_mode:GetBool(2) then
    Exploits.OverrideDoubleTapSpeed(15)
end

if disable_correction:GetBool() then
    CVar.FindVar("cl_clock_correction"):SetInt(0)
    CVar.FindVar("cl_clock_correction_adjustment_max_amount"):SetInt(350)
else
    CVar.FindVar("cl_clock_correction"):SetInt(1)
end

end


end
-- end rage


-- MISC

if enable_misc:GetBool() then


if leg_fucker:GetBool() then
    local legs_int = Utils.RandomInt(0, 10)
    if legs_int < 5 then
        leg_move:SetInt(2)
    end
    if legs_int > 5 then
        leg_move:SetInt(1)
    end
end




end
-- end misc

-- AA


if enable_antiaim:GetBool() then


    if disable_warmup:GetBool() then
        if (EntityList.GetGameRules():GetProp("m_bHasMatchStarted") == false) then
            ref_anti_aim_enable:SetBool(false)
        else
            ref_anti_aim_enable:SetBool(true)
        end
        end


if was_in_use then
    if not FakeLag.Choking() then
        ref_yaw:SetInt(0)
        ref_pitch:SetInt(0)
        ref_left_limit:SetInt(60)
        ref_right_limit:SetInt(60)
    end

    return
end

if Cheat.IsKeyDown(0x20) then

    local lby_int = Utils.RandomInt(0, 10)
        if lby_int < 5 then
            ref_inverter:SetBool(true)
            AntiAim.OverrideLBYOffset(58)
        end
        if lby_int > 5 then
            AntiAim.OverrideLBYOffset(-58)
            ref_inverter:SetBool(false)
        end
    return
end

if (aa_modes:GetInt() == 1) then
    ref_lby_mode:SetInt(1)
    ref_fake_options:SetBool(1, true)
    ref_desync_on_shot:SetBool(1, true)
    AntiAim.OverrideLimit(58)
elseif (aa_modes:GetInt() == 2) then
    ref_lby_mode:SetInt(1)
    ref_fake_options:SetBool(1, true)
    -- ref_fake_options:SetBool(2, true)
    ref_desync_on_shot:SetBool(3, true)
    AntiAim.OverrideLimit(58)
end


if (freestand_type:GetInt() == 0) then
    ref_freestand_desync:SetInt(1)
elseif (freestand_type:GetInt() == 1) then
    ref_freestand_desync:SetInt(2)
end

if ref_slowwalk:GetBool() and low_delta_slow:GetBool() then
    ref_left_limit:SetInt(25)
    ref_right_limit:SetInt(25)
    AntiAim.OverrideLimit(25)

    return

end


if me == nil then return end

        local aa_type = aa_modes:GetInt()

        local local_m_lifeState = me:GetProp("DT_BasePlayer", "m_lifeState")
        if local_m_lifestate then return end
            local cond = condition(me)                   --check condition for local.
            local inverter = AntiAim.GetInverterState()
            if shot_time + 2 > GlobalVars.curtime then
                if anti_brute:GetInt() == 1 then
                     if (miss_counter % 2 == 0) then --Logic 1
                        AntiAim.OverrideLimit(60.0)
                        AntiAim.OverrideYawOffset(4.0)
                        AntiAim.OverrideInverter(true)

                    else if (miss_counter % 2 == 1) then --Logic 2
                        AntiAim.OverrideInverter(false)
                        AntiAim.OverrideLimit(45.0)
                    end
                end
                end
                if anti_brute:GetInt() == 2 then
                     if (miss_counter % 3 == 0) then --Logic 1
                        AntiAim.OverrideLimit(45.0)
                        AntiAim.OverrideInverter(false)

                    else if (miss_counter % 3 == 1) then --Logic 2
                        AntiAim.OverrideLimit(15.0)
                        AntiAim.OverrideInverter(false)
                        AntiAim.OverrideYawOffset(8.0)

                    else if (miss_counter % 3 == 2) then --Logic 3
                        AntiAim.OverrideLimit(60.0)
                        AntiAim.OverrideInverter(true)
                        AntiAim.OverrideYawOffset(8.0)
                        end
                    end
                end
            end
            -- else



    end



end
-- end aa

end







Cheat.RegisterCallback("createmove", function(cmd)
    local me = EntityList:GetLocalPlayer()
    local weap = me:GetPlayer():GetActiveWeapon()
    if not weap then return end
    if was_in_use then
        if not in_bomb_site then
            cmd.buttons = bit.bor(cmd.buttons, bit.lshift(1,5))
        end
        was_in_use = false
        ref_yaw:SetInt(last_yaw)
        ref_pitch:SetInt(last_pitch)
    end
end)



local hstable = {
    "1 H$",
    "morre"
}

local function get_hstable()
    return hstable[Utils.RandomInt(1, #hstable)]:gsub('\"', '')
end

local baimtable = {
    "iq",
    "f12",
    "morre"
}

local function get_baimtable()
    return baimtable[Utils.RandomInt(1, #baimtable)]:gsub('\"', '')
end

local other = {
    knife = '2 facadas 1 pulseira',
    hegrenade = 'Senta',
    inferno = 'queima judeu',
    taser = 'eletrocutado',
}

buybot_delay2 = GlobalVars.curtime + 100000 --1 mill sec to make sure it only triggers 1 time

local function trashtalk_event(event)

    -- TRASHTALK
    if event:GetName() ~= "player_death" then return end

    me = EntityList.GetLocalPlayer()
    victim = EntityList.GetPlayerForUserID(event:GetInt("userid"))
    attacker = EntityList.GetPlayerForUserID(event:GetInt("attacker"))

    weapon_used = event:GetString("weapon", "unknown")

    is_headshot = event:GetBool("headshot", false)


    if victim == attacker or attacker ~= me then return end


    buybot_delay2 = GlobalVars.curtime + 2 --delay time (in sec)
    -- if trashtalk:GetBool() then

    --     if is_headshot then
    --         EngineClient.ExecuteClientCmd('say "' .. get_hstable() .. '"')
    --     elseif not is_headshot and not other[weapon_used] then
    --         EngineClient.ExecuteClientCmd('say "' .. get_baimtable() .. '"')
    --     else
    --         EngineClient.ExecuteClientCmd('say "' .. other[weapon_used] .. '"')
    --     end
   
    -- end


-- TRASHTALK

end



function buybot_draw2()
    if buybot_delay2 < GlobalVars.curtime then

        if is_headshot then
            EngineClient.ExecuteClientCmd('say "' .. get_hstable() .. '"')
        elseif not is_headshot and not other[weapon_used] then
            EngineClient.ExecuteClientCmd('say "' .. get_baimtable() .. '"')
        else
            EngineClient.ExecuteClientCmd('say "' .. other[weapon_used] .. '"')
        end

      buybot_delay2 = GlobalVars.curtime + 1000000 --1 mill sec to make sure it only triggers 1 time
    end
end

verdana = Render.InitFont("Verdana", 12, {'b'})

local function indicators_draw()

    local indicator_color = visual_color:GetColor()
    local inverter_state = AntiAim.GetInverterState()
    local screen = EngineClient:GetScreenSize()

    if not EngineClient:IsConnected() then
        return
    end

    if (indicator_type:GetInt() == 1) then

     
    if inverter_state == true then
    Render.Text("XOXA", Vector2.new(screen.x / 2 - 17, screen.y / 2 + 20), indicator_color, 12, verdana, false, true)
    Render.Text("SYNC", Vector2.new(screen.x / 2 + 17, screen.y / 2 + 20), Color.new(1, 1, 1, 1), 12, verdana, false, true)
    else
    Render.Text("XOXA", Vector2.new(screen.x / 2 - 17, screen.y / 2 + 20), Color.new(1, 1, 1, 1), 12, verdana, false, true)
    Render.Text("SYNC", Vector2.new(screen.x / 2 + 17, screen.y / 2 + 20), indicator_color, 12, verdana, false, true)
    end


    if doubletap then
        Render.Text("double tap", Vector2.new(screen.x / 2, screen.y / 2 + 30), indicator_color, 11, verdana, false, true)
    else
        Render.Text("double tap", Vector2.new(screen.x / 2, screen.y / 2 + 30), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
    end

    if hideshots then
        Render.Text("hide shots", Vector2.new(screen.x / 2, screen.y / 2 + 40), indicator_color, 11, verdana, false, true)
    else
        Render.Text("hide shots", Vector2.new(screen.x / 2, screen.y / 2 + 40), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
    end



    if indicators:GetBool(1) then
        body_size = 60
    else
        body_size = 50
    end

    if indicators:GetBool(1) and indicators:GetBool(2) then
        sp_size = 70
    elseif indicators:GetBool(1) or indicators:GetBool(2) then
        sp_size = 60
    else
        sp_size = 50
    end

    if indicators:GetBool(1) then
        if min_dmg then
            Render.Text("min dmg", Vector2.new(screen.x / 2, screen.y / 2 + 50), indicator_color, 11, verdana, false, true)
        else
            Render.Text("min dmg", Vector2.new(screen.x / 2, screen.y / 2 + 50), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
        end
    end

    if indicators:GetBool(2) then
        if bodyaim then
            Render.Text("body aim", Vector2.new(screen.x / 2, screen.y / 2 + body_size), indicator_color, 11, verdana, false, true)
        else
            Render.Text("body aim", Vector2.new(screen.x / 2, screen.y / 2 + body_size), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
        end
    end


    if indicators:GetBool(3) then
        if safepoint then
            Render.Text("safe point", Vector2.new(screen.x / 2, screen.y / 2 + sp_size), indicator_color, 11, verdana, false, true)
        else
            Render.Text("safe point", Vector2.new(screen.x / 2, screen.y / 2 + sp_size), Color.new(0.6, 0.6, 0.6, 0.6), 11, verdana, false, true)
        end
    end

    end


    local lpx = Vector2.new(screen.x / 2 - 42, screen.y / 2 + 9)
    local lpy = Vector2.new(screen.x / 2 - 42, screen.y / 2 - 9)
    local lpz = Vector2.new(screen.x / 2 - 54, screen.y / 2)

    local rpx = Vector2.new(screen.x / 2 + 42, screen.y / 2 + 9)
    local rpy = Vector2.new(screen.x / 2 + 42, screen.y / 2 - 9)
    local rpz = Vector2.new(screen.x / 2 + 55, screen.y / 2)

    local inactive = Color.new(20 / 255, 20 / 255, 20 / 255, 0.5) -- RGB: 20, 20, 20, 128

    if teamskeet_arrows:GetBool() then

        if manual_aa_side == "Left" then
            Render.PolyFilled(second_color:GetColor(), lpx, lpy, lpz)
        else
            Render.PolyFilled(inactive, lpx, lpy, lpz)
        end
       
        if manual_aa_side == "Right" then
            Render.PolyFilled(second_color:GetColor(), rpx, rpy, rpz)
        else
            Render.PolyFilled(inactive, rpx, rpy, rpz)
        end

        if inverter_state == true then
            Render.BoxFilled(Vector2.new(screen.x / 2 - 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 - 38 , screen.y / 2 + 9), visual_color:GetColor())
        else
            Render.BoxFilled(Vector2.new(screen.x / 2 - 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 - 38, screen.y / 2 + 9), inactive)
        end

        if inverter_state == false then
            Render.BoxFilled(Vector2.new(screen.x / 2 + 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 + 38, screen.y / 2 + 9), visual_color:GetColor())
        else
            Render.BoxFilled(Vector2.new(screen.x / 2 + 40, screen.y / 2 - 9), Vector2.new(screen.x / 2 + 38, screen.y / 2 + 9), inactive)
        end

    end

end



MenuVisibility = function()
    local switch_antiaim = enable_antiaim:GetBool();
    local switch_rage = enable_rage:GetBool();
    local switch_visuals = enable_visuals:GetBool();
    local switch_misc = enable_misc:GetBool();

    -- custom
    -- local da_switch = dormant_aimbot:GetBool()
    local dt_switch = enable_dt:GetBool()
    local arrow_switch = teamskeet_arrows:GetBool()

    legitaa:SetVisible(switch_antiaim);
    aa_modes:SetVisible(switch_antiaim);
    freestand_type:SetVisible(switch_antiaim);
    anti_brute:SetVisible(switch_antiaim);
    low_delta_slow:SetVisible(switch_antiaim);
    disable_warmup:SetVisible(switch_antiaim)

    -- dormant_aimbot:SetVisible(switch_rage);
    -- da_dmg:SetVisible(da_switch and switch_rage);
    enable_dt:SetVisible(switch_rage);
    dt_mode:SetVisible(dt_switch and switch_rage);
    disable_correction:SetVisible(dt_switch and switch_rage);
    anti_defensive:SetVisible(switch_rage)
   
 

    -- visual_color:SetVisible(switch_visuals);
    indicators:SetVisible(switch_visuals);
    indicator_type:SetVisible(switch_visuals);
    visual_color:SetVisible(switch_visuals);
    teamskeet_arrows:SetVisible(switch_visuals);
    second_color:SetVisible(switch_visuals and arrow_switch);
    pulsate_alpha:SetVisible(switch_visuals)

    leg_fucker:SetVisible(switch_misc);
    trashtalk:SetVisible(switch_misc)


end

enable_antiaim:RegisterCallback(MenuVisibility);
enable_rage:RegisterCallback(MenuVisibility);
enable_visuals:RegisterCallback(MenuVisibility);
enable_misc:RegisterCallback(MenuVisibility);

-- custom
-- dormant_aimbot:RegisterCallback(MenuVisibility);

enable_dt:RegisterCallback(MenuVisibility);
teamskeet_arrows:RegisterCallback(MenuVisibility)

MenuVisibility();

Cheat.AddNotify("xoxasync", "Welcome, " .. username .. " ")


local function events(event)

    trashtalk_event(event)
    antibrute(event)
    impacts_events(event)

end

Cheat.RegisterCallback("events", events)


Cheat.RegisterCallback("prediction", function()
on_createmove()
end)

Cheat.RegisterCallback("pre_prediction", function(cmd)
    legit_aa(cmd)
end)

Cheat.RegisterCallback("draw", function()
    handle_binds()
    indicators_draw()
end)

Cheat.RegisterCallback("frame_stage", function()
    buybot_draw2()
  end)
Боже мой...
 
Эксперт
Статус
Оффлайн
Регистрация
10 Фев 2021
Сообщения
1,740
Реакции[?]
559
Поинты[?]
2K
local function handle_binds() local binds = Cheat.GetBinds() for i = 1, #binds do if binds:GetName() == "Minimum Damage" and binds:IsActive() then min_dmg = true min_dmg_dmg = binds:GetValue() end if binds:GetName() == "Minimum Damage" and not binds:IsActive() then min_dmg = false end if binds:GetName() == "Double Tap" and binds:IsActive() then doubletap = true end if binds:GetName() == "Double Tap" and not binds:IsActive() then doubletap = false end if binds:GetName() == "Hide Shots" and binds:IsActive() then hideshots = true end if binds:GetName() == "Hide Shots" and not binds:IsActive() then hideshots = false end if binds:GetName() == "Auto Peek" and binds:IsActive() then quickpeek = true end if binds:GetName() == "Auto Peek" and not binds:IsActive() then quickpeek = false end if binds:GetName() == "Fake Duck" and binds:IsActive() then fakeduck = true end if binds:GetName() == "Fake Duck" and not binds:IsActive() then fakeduck = false end if binds:GetName() == "Body Aim" and binds:IsActive() then bodyaim = true end if binds:GetName() == "Body Aim" and not binds:IsActive() then bodyaim = false end if binds:GetName() == "Safe Points" and binds:IsActive() then safepoint = true end if binds:GetName() == "Safe Points" and not binds:IsActive() then safepoint = false end if binds:GetName() == "Yaw Base" and binds:IsActive() then manual_aa = true manual_aa_side = binds:GetValue() end if binds:GetName() == "Yaw Base" and not binds:IsActive() then manual_aa = false end end end
это что за пищлец
 
Забаненный
Статус
Оффлайн
Регистрация
20 Фев 2022
Сообщения
149
Реакции[?]
41
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
local other = {
knife = '2 facadas 1 pulseira',
hegrenade = 'Senta',
inferno = 'queima judeu',
taser = 'eletrocutado',
}

mega funny moment
 
Забаненный
Статус
Оффлайн
Регистрация
6 Сен 2021
Сообщения
94
Реакции[?]
22
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Сверху Снизу