C++ Custom scope lines for lw

Начинающий
Статус
Оффлайн
Регистрация
10 Апр 2022
Сообщения
85
Реакции[?]
8
Поинты[?]
4K
может кому-то понадобится, хоть что-то новое в свою пасту добавить)
Код:
void otheresp::custom_scopes_lines()
{
    if (!g_ctx.local()->is_alive()) //-V807
        return;

    if (!g_cfg.esp.removals[REMOVALS_SCOPE])
        return;

    if (!g_cfg.esp.custom_scopes_line)
        return;

    auto weapon = g_ctx.local()->m_hActiveWeapon().Get();

    if (!weapon)
        return;

    auto is_scoped = g_ctx.globals.scoped && weapon->is_sniper() && weapon->m_zoomLevel();

    if (!is_scoped)
        return;

    static int width, height;
    m_engine()->GetScreenSize(width, height);

    auto offset = g_cfg.esp.scopes_line_offset;
    auto leng = g_cfg.esp.scopes_line_width;
    auto accent = g_cfg.esp.scopes_line_color;
    auto accent2 = Color(g_cfg.esp.scopes_line_color.r(), g_cfg.esp.scopes_line_color.g(), g_cfg.esp.scopes_line_color.b(), 0);

    render::get().gradient(width / 2 + offset, height / 2, leng, 1, accent, accent2, GradientType::GRADIENT_HORIZONTAL);
    render::get().gradient(width / 2 - leng - offset, height / 2, leng, 1, accent2, accent, GradientType::GRADIENT_HORIZONTAL);
    render::get().gradient(width / 2, height / 2 + offset, 1, leng, accent, accent2, GradientType::GRADIENT_VERTICAL);
    render::get().gradient(width / 2, height / 2 - leng - offset, 1, leng, accent2, accent, GradientType::GRADIENT_VERTICAL);
}
 
Начинающий
Статус
Оффлайн
Регистрация
6 Мар 2021
Сообщения
106
Реакции[?]
16
Поинты[?]
12K
может кому-то понадобится, хоть что-то новое в свою пасту добавить)
Код:
void otheresp::custom_scopes_lines()
{
    if (!g_ctx.local()->is_alive()) //-V807
        return;

    if (!g_cfg.esp.removals[REMOVALS_SCOPE])
        return;

    if (!g_cfg.esp.custom_scopes_line)
        return;

    auto weapon = g_ctx.local()->m_hActiveWeapon().Get();

    if (!weapon)
        return;

    auto is_scoped = g_ctx.globals.scoped && weapon->is_sniper() && weapon->m_zoomLevel();

    if (!is_scoped)
        return;

    static int width, height;
    m_engine()->GetScreenSize(width, height);

    auto offset = g_cfg.esp.scopes_line_offset;
    auto leng = g_cfg.esp.scopes_line_width;
    auto accent = g_cfg.esp.scopes_line_color;
    auto accent2 = Color(g_cfg.esp.scopes_line_color.r(), g_cfg.esp.scopes_line_color.g(), g_cfg.esp.scopes_line_color.b(), 0);

    render::get().gradient(width / 2 + offset, height / 2, leng, 1, accent, accent2, GradientType::GRADIENT_HORIZONTAL);
    render::get().gradient(width / 2 - leng - offset, height / 2, leng, 1, accent2, accent, GradientType::GRADIENT_HORIZONTAL);
    render::get().gradient(width / 2, height / 2 + offset, 1, leng, accent, accent2, GradientType::GRADIENT_VERTICAL);
    render::get().gradient(width / 2, height / 2 - leng - offset, 1, leng, accent2, accent, GradientType::GRADIENT_VERTICAL);
}
на юге такой же был, у меня друг даже добавлял к себе в пасту такой
 
Сверху Снизу