• На форуме разыгрывается более 300 ключей на приватные читы! Для этого нужно всего-лишь нажать соответствующую кнопку в теме!

    Подробности по ссылке:
    https://t.me/yougame_official/66

Вопрос Помогите починить leg fucker

Начинающий
Статус
Оффлайн
Регистрация
13 Сен 2022
Сообщения
40
Реакции[?]
2
Поинты[?]
0
Что делать если legfucker в неверлузе перестаёт работать после нажатия фд или отжатия дт
 
she/her
Пользователь
Статус
Оффлайн
Регистрация
29 Сен 2022
Сообщения
294
Реакции[?]
118
Поинты[?]
27K
а ну тут мега изи ты ток код скинь братишка я все сделаю ахуенно
 
Начинающий
Статус
Оффлайн
Регистрация
13 Сен 2022
Сообщения
40
Реакции[?]
2
Поинты[?]
0
а ну тут мега изи ты ток код скинь братишка я все сделаю ахуенно
Код хоть скинь
Код:
local ffi = require("ffi")
ffi.cdef[[
    
  
bool DeleteUrlCacheEntryA(const char* lpszUrlName);
void* __stdcall URLDownloadToFileA(void* LPUNKNOWN, const char* LPCSTR, const char* LPCSTR2, int a, int LPBINDSTATUSCALLBACK);

typedef struct
{
    float x;
    float y;
    float z;
} Vector_t;

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 uintptr_t (__thiscall* GetClientEntity_4242425_t)(void*, int);

typedef struct {
    uint8_t r;
    uint8_t g;
    uint8_t b;
    uint8_t a;
} color_struct_t;

typedef void (__cdecl* console_color_print)(void*,const color_struct_t&, const char*, ...);

typedef struct
{
    char    pad0[0x60]; // 0x00
    void* pEntity; // 0x60
    void* pActiveWeapon; // 0x64
    void* pLastActiveWeapon; // 0x68
    float        flLastUpdateTime; // 0x6C
    int            iLastUpdateFrame; // 0x70
    float        flLastUpdateIncrement; // 0x74
    float        flEyeYaw; // 0x78
    float        flEyePitch; // 0x7C
    float        flGoalFeetYaw; // 0x80
    float        flLastFeetYaw; // 0x84
    float        flMoveYaw; // 0x88
    float        flLastMoveYaw; // 0x8C // changes when moving/jumping/hitting ground
    float        flLeanAmount; // 0x90
    char         pad1[0x4]; // 0x94
    float        flFeetCycle; // 0x98 0 to 1
    float        flMoveWeight; // 0x9C 0 to 1
    float        flMoveWeightSmoothed; // 0xA0
    float        flDuckAmount; // 0xA4
    float        flHitGroundCycle; // 0xA8
    float        flRecrouchWeight; // 0xAC
    Vector_t        vecOrigin; // 0xB0
    Vector_t        vecLastOrigin;// 0xBC
    Vector_t        vecVelocity; // 0xC8
    Vector_t        vecVelocityNormalized; // 0xD4
    Vector_t        vecVelocityNormalizedNonZero; // 0xE0
    float        flVelocityLenght2D; // 0xEC
    float        flJumpFallVelocity; // 0xF0
    float        flSpeedNormalized; // 0xF4 // clamped velocity from 0 to 1
    float        flRunningSpeed; // 0xF8
    float        flDuckingSpeed; // 0xFC
    float        flDurationMoving; // 0x100
    float        flDurationStill; // 0x104
    bool        bOnGround; // 0x108
    bool        bHitGroundAnimation; // 0x109
    char    pad2[0x2]; // 0x10A
    float        flNextLowerBodyYawUpdateTime; // 0x10C
    float        flDurationInAir; // 0x110
    float        flLeftGroundHeight; // 0x114
    float        flHitGroundWeight; // 0x118 // from 0 to 1, is 1 when standing
    float        flWalkToRunTransition; // 0x11C // from 0 to 1, doesnt change when walking or crouching, only running
    char    pad3[0x4]; // 0x120
    float        flAffectedFraction; // 0x124 // affected while jumping and running, or when just jumping, 0 to 1
    char    pad4[0x208]; // 0x128
    float        flMinBodyYaw; // 0x330
    float        flMaxBodyYaw; // 0x334
    float        flMinPitch; //0x338
    float        flMaxPitch; // 0x33C
    int            iAnimsetVersion; // 0x340
} CCSGOPlayerAnimationState_534535_t;
    typedef struct {
        char  pad_0000[20];
        int m_nOrder; //0x0014
        int m_nSequence; //0x0018
        float m_flPrevCycle; //0x001C
        float m_flWeight; //0x0020
        float m_flWeightDeltaRate; //0x0024
        float m_flPlaybackRate; //0x0028
        float m_flCycle; //0x002C
        void *m_pOwner; //0x0030
        float m_flModelScale;
        char  pad_0038[4]; //0x0034
    } CAnimationLayer;
    typedef struct {
        float x;
        float y;
        float z;
    } vec3_struct;

    typedef void*(__thiscall* c_entity_list_get_client_entity_t)(void*, int);
    typedef void*(__thiscall* c_entity_list_get_client_entity_from_handle_t)(void*, uintptr_t);

    typedef int(__thiscall* c_weapon_get_muzzle_attachment_index_first_person_t)(void*, void*);
    typedef int(__thiscall* c_weapon_get_muzzle_attachment_index_third_person_t)(void*);
    typedef bool(__thiscall* c_entity_get_attachment_t)(void*, int, vec3_struct*);
 
    bool CreateDirectoryA(const char* lpPathName, void* lpSecurityAttributes);
    void* __stdcall URLDownloadToFileA(void* LPUNKNOWN, const char* LPCSTR, const char* LPCSTR2, int a, int LPBINDSTATUSCALLBACK);
    void* __stdcall ShellExecuteA(void* hwnd, const char* op, const char* file, const char* params, const char* dir, int show_cmd);

    bool DeleteUrlCacheEntryA(const char* lpszUrlName);

    void*     CreateFileA(const char*, uintptr_t, uintptr_t, void*, uintptr_t, uintptr_t, void*);
    uintptr_t GetFileSize(void*, uintptr_t*);
    int       ReadFile(void*, void*, uintptr_t, uintptr_t*, void*);
    int       WriteFile(void*, const void*, uintptr_t, uintptr_t*, void*);
    int       CloseHandle(void*);
    typedef struct {
        uint8_t r;
        uint8_t g;
        uint8_t b;
        uint8_t a;
    } color_struct_t;

    typedef void (*console_color_print)(void*, const color_struct_t&, const char*, ...);

    typedef int(__thiscall* get_clipboard_text_length)(void*);
    typedef void(__thiscall* set_clipboard_text)(void*, const char*, int);
    typedef void(__thiscall* get_clipboard_text)(void*, int, const char*, int);
    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 uintptr_t (__thiscall* GetClientEntity_4242425_t)(void*, int);
    int MessageBoxA(void *w, const char *txt, const char *cap, int type);
    
    typedef int BOOL;
    typedef unsigned long HANDLE;
    typedef unsigned long DWORD;
    typedef unsigned long UINT;
    typedef HANDLE HWND;
    typedef int bInvert;

]]


antiAim = ui.create('AA',"AA", 2)
animBreaker = antiAim:switch('AnimBreaker', false)


vmt_hook = {hooks = {}}
hooked_function = nil

function updateCSA_hk(thisptr, edx)
    local local_player = entity.get_local_player()
    local lp_ptr = get_entity_address(local_player:get_index())
    if local_player == nil or ffi.cast('uintptr_t', thisptr) == nil then return end
    hooked_function(thisptr, edx)
    if animBreaker:get() then
        ui.find("Aimbot", "Anti Aim","Misc", "Leg Movement"):override('Sliding')
        ffi.cast("float*", ffi.cast("uintptr_t", thisptr) + 10104)[0] = globals.tickcount%4 == 2 and 0.5 or 1.5
    end
end
hook_helper = {
    copy = function(dst, src, len)
    return ffi.copy(ffi.cast('void*', dst), ffi.cast('const void*', src), len)
    end,

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

    virtual_alloc = function(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
}
buff = {free = {}}
vmt_hook = {hooks = {}}
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, zxcvb, method)
    org_func[method] = virtual_table[method]
    hook_helper.virtual_protect(virtual_table + method, 4, 0x4, old_prot)

    virtual_table[method] = ffi.cast('intptr_t', ffi.cast(cast, zxcvb))
    hook_helper.virtual_protect(virtual_table + method, 4, old_prot[0], old_prot)

    return ffi.cast(cast, org_func[method])
end
new_hook.unHookMethod = function(method)
    hook_helper.virtual_protect(virtual_table + method, 4, 0x4, old_prot)
    local alloc_addr = hook_helper.virtual_alloc(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

    hook_helper.copy(alloc_addr, trampoline_bytes, 5)
    virtual_table[method] = ffi.cast('intptr_t', alloc_addr)

    hook_helper.virtual_protect(virtual_table + method, 4, old_prot[0], old_prot)
    org_func[method] = nil
end

new_hook.unHookAll = function()
    for method, zxcvb in pairs(org_func) do
        new_hook.unHookMethod(method)
    end
end

table.insert(vmt_hook.hooks, new_hook.unHookAll)
    return new_hook
end

entity_list_pointer = ffi.cast('void***', utils.create_interface('client.dll', 'VClientEntityList003'))
get_client_entity_fn = ffi.cast('GetClientEntity_4242425_t', entity_list_pointer[0][3])
function get_entity_address(ent_index)
    local addr = get_client_entity_fn(entity_list_pointer, ent_index)
    return addr
end

function anim_state_hook()
    local local_player = entity.get_local_player()
    if local_player == nil then return end

    local local_player_ptr = get_entity_address(local_player:get_index())
    if local_player_ptr == nil or hooked_function then return end
    local C_CSPLAYER = vmt_hook.new(local_player_ptr)
    hooked_function = C_CSPLAYER.hookMethod('void(__fastcall*)(void*, void*)', updateCSA_hk, 224)
end

events.createmove:set(function()
    anim_state_hook()
end)

events.shutdown:set(function()
    for _, reset_function in ipairs(vmt_hook.hooks) do
        reset_function()
    end
end)
 
Модератор раздела "Создание скриптов для читов"
Модератор
Статус
Оффлайн
Регистрация
1 Фев 2020
Сообщения
1,253
Реакции[?]
423
Поинты[?]
63K
Код:
local ffi = require("ffi")
ffi.cdef[[
   
 
bool DeleteUrlCacheEntryA(const char* lpszUrlName);
void* __stdcall URLDownloadToFileA(void* LPUNKNOWN, const char* LPCSTR, const char* LPCSTR2, int a, int LPBINDSTATUSCALLBACK);

typedef struct
{
    float x;
    float y;
    float z;
} Vector_t;

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 uintptr_t (__thiscall* GetClientEntity_4242425_t)(void*, int);

typedef struct {
    uint8_t r;
    uint8_t g;
    uint8_t b;
    uint8_t a;
} color_struct_t;

typedef void (__cdecl* console_color_print)(void*,const color_struct_t&, const char*, ...);

typedef struct
{
    char    pad0[0x60]; // 0x00
    void* pEntity; // 0x60
    void* pActiveWeapon; // 0x64
    void* pLastActiveWeapon; // 0x68
    float        flLastUpdateTime; // 0x6C
    int            iLastUpdateFrame; // 0x70
    float        flLastUpdateIncrement; // 0x74
    float        flEyeYaw; // 0x78
    float        flEyePitch; // 0x7C
    float        flGoalFeetYaw; // 0x80
    float        flLastFeetYaw; // 0x84
    float        flMoveYaw; // 0x88
    float        flLastMoveYaw; // 0x8C // changes when moving/jumping/hitting ground
    float        flLeanAmount; // 0x90
    char         pad1[0x4]; // 0x94
    float        flFeetCycle; // 0x98 0 to 1
    float        flMoveWeight; // 0x9C 0 to 1
    float        flMoveWeightSmoothed; // 0xA0
    float        flDuckAmount; // 0xA4
    float        flHitGroundCycle; // 0xA8
    float        flRecrouchWeight; // 0xAC
    Vector_t        vecOrigin; // 0xB0
    Vector_t        vecLastOrigin;// 0xBC
    Vector_t        vecVelocity; // 0xC8
    Vector_t        vecVelocityNormalized; // 0xD4
    Vector_t        vecVelocityNormalizedNonZero; // 0xE0
    float        flVelocityLenght2D; // 0xEC
    float        flJumpFallVelocity; // 0xF0
    float        flSpeedNormalized; // 0xF4 // clamped velocity from 0 to 1
    float        flRunningSpeed; // 0xF8
    float        flDuckingSpeed; // 0xFC
    float        flDurationMoving; // 0x100
    float        flDurationStill; // 0x104
    bool        bOnGround; // 0x108
    bool        bHitGroundAnimation; // 0x109
    char    pad2[0x2]; // 0x10A
    float        flNextLowerBodyYawUpdateTime; // 0x10C
    float        flDurationInAir; // 0x110
    float        flLeftGroundHeight; // 0x114
    float        flHitGroundWeight; // 0x118 // from 0 to 1, is 1 when standing
    float        flWalkToRunTransition; // 0x11C // from 0 to 1, doesnt change when walking or crouching, only running
    char    pad3[0x4]; // 0x120
    float        flAffectedFraction; // 0x124 // affected while jumping and running, or when just jumping, 0 to 1
    char    pad4[0x208]; // 0x128
    float        flMinBodyYaw; // 0x330
    float        flMaxBodyYaw; // 0x334
    float        flMinPitch; //0x338
    float        flMaxPitch; // 0x33C
    int            iAnimsetVersion; // 0x340
} CCSGOPlayerAnimationState_534535_t;
    typedef struct {
        char  pad_0000[20];
        int m_nOrder; //0x0014
        int m_nSequence; //0x0018
        float m_flPrevCycle; //0x001C
        float m_flWeight; //0x0020
        float m_flWeightDeltaRate; //0x0024
        float m_flPlaybackRate; //0x0028
        float m_flCycle; //0x002C
        void *m_pOwner; //0x0030
        float m_flModelScale;
        char  pad_0038[4]; //0x0034
    } CAnimationLayer;
    typedef struct {
        float x;
        float y;
        float z;
    } vec3_struct;

    typedef void*(__thiscall* c_entity_list_get_client_entity_t)(void*, int);
    typedef void*(__thiscall* c_entity_list_get_client_entity_from_handle_t)(void*, uintptr_t);

    typedef int(__thiscall* c_weapon_get_muzzle_attachment_index_first_person_t)(void*, void*);
    typedef int(__thiscall* c_weapon_get_muzzle_attachment_index_third_person_t)(void*);
    typedef bool(__thiscall* c_entity_get_attachment_t)(void*, int, vec3_struct*);

    bool CreateDirectoryA(const char* lpPathName, void* lpSecurityAttributes);
    void* __stdcall URLDownloadToFileA(void* LPUNKNOWN, const char* LPCSTR, const char* LPCSTR2, int a, int LPBINDSTATUSCALLBACK);
    void* __stdcall ShellExecuteA(void* hwnd, const char* op, const char* file, const char* params, const char* dir, int show_cmd);

    bool DeleteUrlCacheEntryA(const char* lpszUrlName);

    void*     CreateFileA(const char*, uintptr_t, uintptr_t, void*, uintptr_t, uintptr_t, void*);
    uintptr_t GetFileSize(void*, uintptr_t*);
    int       ReadFile(void*, void*, uintptr_t, uintptr_t*, void*);
    int       WriteFile(void*, const void*, uintptr_t, uintptr_t*, void*);
    int       CloseHandle(void*);
    typedef struct {
        uint8_t r;
        uint8_t g;
        uint8_t b;
        uint8_t a;
    } color_struct_t;

    typedef void (*console_color_print)(void*, const color_struct_t&, const char*, ...);

    typedef int(__thiscall* get_clipboard_text_length)(void*);
    typedef void(__thiscall* set_clipboard_text)(void*, const char*, int);
    typedef void(__thiscall* get_clipboard_text)(void*, int, const char*, int);
    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 uintptr_t (__thiscall* GetClientEntity_4242425_t)(void*, int);
    int MessageBoxA(void *w, const char *txt, const char *cap, int type);
   
    typedef int BOOL;
    typedef unsigned long HANDLE;
    typedef unsigned long DWORD;
    typedef unsigned long UINT;
    typedef HANDLE HWND;
    typedef int bInvert;

]]


antiAim = ui.create('AA',"AA", 2)
animBreaker = antiAim:switch('AnimBreaker', false)


vmt_hook = {hooks = {}}
hooked_function = nil

function updateCSA_hk(thisptr, edx)
    local local_player = entity.get_local_player()
    local lp_ptr = get_entity_address(local_player:get_index())
    if local_player == nil or ffi.cast('uintptr_t', thisptr) == nil then return end
    hooked_function(thisptr, edx)
    if animBreaker:get() then
        ui.find("Aimbot", "Anti Aim","Misc", "Leg Movement"):override('Sliding')
        ffi.cast("float*", ffi.cast("uintptr_t", thisptr) + 10104)[0] = globals.tickcount%4 == 2 and 0.5 or 1.5
    end
end
hook_helper = {
    copy = function(dst, src, len)
    return ffi.copy(ffi.cast('void*', dst), ffi.cast('const void*', src), len)
    end,

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

    virtual_alloc = function(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
}
buff = {free = {}}
vmt_hook = {hooks = {}}
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, zxcvb, method)
    org_func[method] = virtual_table[method]
    hook_helper.virtual_protect(virtual_table + method, 4, 0x4, old_prot)

    virtual_table[method] = ffi.cast('intptr_t', ffi.cast(cast, zxcvb))
    hook_helper.virtual_protect(virtual_table + method, 4, old_prot[0], old_prot)

    return ffi.cast(cast, org_func[method])
end
new_hook.unHookMethod = function(method)
    hook_helper.virtual_protect(virtual_table + method, 4, 0x4, old_prot)
    local alloc_addr = hook_helper.virtual_alloc(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

    hook_helper.copy(alloc_addr, trampoline_bytes, 5)
    virtual_table[method] = ffi.cast('intptr_t', alloc_addr)

    hook_helper.virtual_protect(virtual_table + method, 4, old_prot[0], old_prot)
    org_func[method] = nil
end

new_hook.unHookAll = function()
    for method, zxcvb in pairs(org_func) do
        new_hook.unHookMethod(method)
    end
end

table.insert(vmt_hook.hooks, new_hook.unHookAll)
    return new_hook
end

entity_list_pointer = ffi.cast('void***', utils.create_interface('client.dll', 'VClientEntityList003'))
get_client_entity_fn = ffi.cast('GetClientEntity_4242425_t', entity_list_pointer[0][3])
function get_entity_address(ent_index)
    local addr = get_client_entity_fn(entity_list_pointer, ent_index)
    return addr
end

function anim_state_hook()
    local local_player = entity.get_local_player()
    if local_player == nil then return end

    local local_player_ptr = get_entity_address(local_player:get_index())
    if local_player_ptr == nil or hooked_function then return end
    local C_CSPLAYER = vmt_hook.new(local_player_ptr)
    hooked_function = C_CSPLAYER.hookMethod('void(__fastcall*)(void*, void*)', updateCSA_hk, 224)
end

events.createmove:set(function()
    anim_state_hook()
end)

events.shutdown:set(function()
    for _, reset_function in ipairs(vmt_hook.hooks) do
        reset_function()
    end
end)
ебать ты сюда напастил..

Пожалуйста, авторизуйтесь для просмотра ссылки.
вот тебе нормальный код
 
Сверху Снизу