Вопрос Моделька игрока в esp preview

Рисую демонической кровью
Забаненный
Забаненный
Статус
Оффлайн
Регистрация
10 Дек 2021
Сообщения
124
Реакции
46
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Привет, форумчане.

Возник вопрос как добавить модельку игрока в esp preview, и позже рисовать на ней вх(не имеет значение какая игра).
 
Просто добавь картинку модельки и возьми отсюда код (код конечно написан для ксго но лан)
Пожалуйста, авторизуйтесь для просмотра ссылки.
(noad)
 
Very simple way to do it in csgo

C++:
Expand Collapse Copy
#include <sdk/IVModelRender.h>

// Function to draw player model in ESP preview
void draw_player_model(const C_BaseEntity *player, const Vector &origin, const QAngle &angles) {
    // Get model render interface
    IVModelRender *pModelRender = g_pModelRender;

    // Set up model render data
    model_render_info_t render_info;
    render_info.origin = origin;
    render_info.angles = angles;
    render_info.pModel = player->GetModel();
    render_info.pRenderable = player;
    render_info.flags = STUDIO_RENDER;

    // Set up lighting data
    lighting_query_t lighting;
    lighting.pos = origin;
    lighting.normal = Vector(0.0f, 0.0f, 1.0f);
    lighting.ambient_light_color = Color(255, 255, 255, 255);
    lighting.direct_light_color = Color(255, 255, 255, 255);
    lighting.pMaterial = nullptr;
    lighting.flags = LIGHTING_LIGHT_AMBIENT | LIGHTING_LIGHT_DIRECT;

    // Set up lighting state
    lighting_state_t lighting_state;
    lighting_state.pLighting = &lighting;
    lighting_state.pLightingState = &lighting_state;

    // Draw player model
    pModelRender->DrawModelEx(render_info, lighting_state);
}


int main() {
    // Initialize player model and preview window
    // ...

    // Loop through all player entities
    for (int i = 1; i <= g_pGlobalVars->maxClients; i++) {
        // Get player entity
        C_BaseEntity *player = g_pEntityList->GetClientEntity(i);
        if (!player || player->GetDormant() || player->GetHealth() <= 0) continue; // skip inactive or dead players

        // Draw player model in preview window
        draw_player_model(player, player->GetAbsOrigin(), player->GetAbsAngles());
    }

    // Handle user input and update preview window
    // ...
}
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Very simple way to do it in csgo

C++:
Expand Collapse Copy
#include <sdk/IVModelRender.h>

// Function to draw player model in ESP preview
void draw_player_model(const C_BaseEntity *player, const Vector &origin, const QAngle &angles) {
    // Get model render interface
    IVModelRender *pModelRender = g_pModelRender;

    // Set up model render data
    model_render_info_t render_info;
    render_info.origin = origin;
    render_info.angles = angles;
    render_info.pModel = player->GetModel();
    render_info.pRenderable = player;
    render_info.flags = STUDIO_RENDER;

    // Set up lighting data
    lighting_query_t lighting;
    lighting.pos = origin;
    lighting.normal = Vector(0.0f, 0.0f, 1.0f);
    lighting.ambient_light_color = Color(255, 255, 255, 255);
    lighting.direct_light_color = Color(255, 255, 255, 255);
    lighting.pMaterial = nullptr;
    lighting.flags = LIGHTING_LIGHT_AMBIENT | LIGHTING_LIGHT_DIRECT;

    // Set up lighting state
    lighting_state_t lighting_state;
    lighting_state.pLighting = &lighting;
    lighting_state.pLightingState = &lighting_state;

    // Draw player model
    pModelRender->DrawModelEx(render_info, lighting_state);
}


int main() {
    // Initialize player model and preview window
    // ...

    // Loop through all player entities
    for (int i = 1; i <= g_pGlobalVars->maxClients; i++) {
        // Get player entity
        C_BaseEntity *player = g_pEntityList->GetClientEntity(i);
        if (!player || player->GetDormant() || player->GetHealth() <= 0) continue; // skip inactive or dead players

        // Draw player model in preview window
        draw_player_model(player, player->GetAbsOrigin(), player->GetAbsAngles());
    }

    // Handle user input and update preview window
    // ...
}
Thx
 
  • Мне нравится
Реакции: r9x
Назад
Сверху Снизу