Исходник Attachment chams/Thirdperson weapon chams

Начинающий
Статус
Оффлайн
Регистрация
23 Окт 2020
Сообщения
33
Реакции[?]
20
Поинты[?]
0
Paste in hooked_dme.cpp at line 57-
Код:
auto weapon_on_back = strstr(name, "_dropped.mdl") && strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto weapon_enemy_hands = strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto defuse_kit = strstr(name, "defuser") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
replace the line at 61-
Код:
if (m_modelrender()->IsForcedMaterialOverride() && !is_weapon && !is_arms && !is_sleeve && !weapon_on_back && !weapon_enemy_hands && !defuse_kit)
replace the line at 66-
Код:
if (!is_player && !is_weapon && !is_arms && !is_sleeve && !weapon_on_back && !weapon_enemy_hands && !defuse_kit)
now add this at line 810-
Код:
    else if (weapon_on_back)
    {
        auto alpha = (float)g_cfg.esp.attachment_chams_color.a() / 255.0f;

        auto material = materials[g_cfg.esp.attachment_chams_material];
        auto double_material = materials[6];

        if (material && double_material && !material->IsErrorMaterial() && !double_material->IsErrorMaterial())
        {
            float attachment_color[3] =
            {
                g_cfg.esp.attachment_chams_color[0] / 255.0f,
                g_cfg.esp.attachment_chams_color[1] / 255.0f,
                g_cfg.esp.attachment_chams_color[2] / 255.0f
            };

            m_renderview()->SetBlend(alpha);
            util::color_modulate(attachment_color, material);

            material->IncrementReferenceCount();
            material->SetMaterialVarFlag(MATERIAL_VAR_IGNOREZ, false);

            m_modelrender()->ForcedMaterialOverride(material);
            original_fn(m_modelrender(), ctx, state, info, bone_to_world);
            m_modelrender()->ForcedMaterialOverride(nullptr);

            if (g_cfg.esp.attachment_double_material && g_cfg.esp.attachment_chams_material != 6)
            {
                alpha = (float)g_cfg.esp.attachment_double_material_color.a() / 255.0f;

                float double_color[3] =
                {
                    g_cfg.esp.attachment_double_material_color[0] / 255.0f,
                    g_cfg.esp.attachment_double_material_color[1] / 255.0f,
                    g_cfg.esp.attachment_double_material_color[2] / 255.0f
                };

                m_renderview()->SetBlend(alpha);
                util::color_modulate(double_color, double_material);

                double_material->IncrementReferenceCount();
                double_material->SetMaterialVarFlag(MATERIAL_VAR_IGNOREZ, false);

                m_modelrender()->ForcedMaterialOverride(double_material);
                original_fn(m_modelrender(), ctx, state, info, bone_to_world);
                m_modelrender()->ForcedMaterialOverride(nullptr);
            }

            called_original = true;
        }

        if (!called_original)
            return original_fn(m_modelrender(), ctx, state, info, bone_to_world);
    }
    else if (weapon_enemy_hands)
    {
        auto alpha = (float)g_cfg.esp.attachment_chams_color.a() / 255.0f;
        
        auto material = materials[g_cfg.esp.attachment_chams_material];
        auto double_material = materials[6];

        if (material && double_material && !material->IsErrorMaterial() && !double_material->IsErrorMaterial())
        {
            float attachment_color[3] =
            {
                g_cfg.esp.attachment_chams_color[0] / 255.0f,
                g_cfg.esp.attachment_chams_color[1] / 255.0f,
                g_cfg.esp.attachment_chams_color[2] / 255.0f
            };

            m_renderview()->SetBlend(alpha);
            util::color_modulate(attachment_color, material);

            material->IncrementReferenceCount();
            material->SetMaterialVarFlag(MATERIAL_VAR_IGNOREZ, false);

            m_modelrender()->ForcedMaterialOverride(material);
            original_fn(m_modelrender(), ctx, state, info, bone_to_world);
            m_modelrender()->ForcedMaterialOverride(nullptr);

            if (g_cfg.esp.attachment_double_material && g_cfg.esp.attachment_chams_material != 6)
            {
                alpha = (float)g_cfg.esp.attachment_double_material_color.a() / 255.0f;

                float double_color[3] =
                {
                    g_cfg.esp.attachment_double_material_color[0] / 255.0f,
                    g_cfg.esp.attachment_double_material_color[1] / 255.0f,
                    g_cfg.esp.attachment_double_material_color[2] / 255.0f
                };

                m_renderview()->SetBlend(alpha);
                util::color_modulate(double_color, double_material);

                double_material->IncrementReferenceCount();
                double_material->SetMaterialVarFlag(MATERIAL_VAR_IGNOREZ, false);

                m_modelrender()->ForcedMaterialOverride(double_material);
                original_fn(m_modelrender(), ctx, state, info, bone_to_world);
                m_modelrender()->ForcedMaterialOverride(nullptr);
            }

            called_original = true;
        }

        if (!called_original)
            return original_fn(m_modelrender(), ctx, state, info, bone_to_world);
    }
    else if (defuse_kit)
    {
        auto alpha = (float)g_cfg.esp.attachment_chams_color.a() / 255.0f;
     
        auto material = materials[g_cfg.esp.attachment_chams_material];
        auto double_material = materials[6];

        if (material && double_material && !material->IsErrorMaterial() && !double_material->IsErrorMaterial())
        {
            float attachment_color[3] =
            {
                g_cfg.esp.attachment_chams_color[0] / 255.0f,
                g_cfg.esp.attachment_chams_color[1] / 255.0f,
                g_cfg.esp.attachment_chams_color[2] / 255.0f
            };

            m_renderview()->SetBlend(alpha);
            util::color_modulate(attachment_color, material);

            material->IncrementReferenceCount();
            material->SetMaterialVarFlag(MATERIAL_VAR_IGNOREZ, false);

            m_modelrender()->ForcedMaterialOverride(material);
            original_fn(m_modelrender(), ctx, state, info, bone_to_world);
            m_modelrender()->ForcedMaterialOverride(nullptr);

            if (g_cfg.esp.attachment_double_material && g_cfg.esp.attachment_chams_material != 6)
            {
                alpha = (float)g_cfg.esp.attachment_double_material_color.a() / 255.0f;

                float double_color[3] =
                {
                    g_cfg.esp.attachment_double_material_color[0] / 255.0f,
                    g_cfg.esp.attachment_double_material_color[1] / 255.0f,
                    g_cfg.esp.attachment_double_material_color[2] / 255.0f
                };

                m_renderview()->SetBlend(alpha);
                util::color_modulate(double_color, double_material);

                double_material->IncrementReferenceCount();
                double_material->SetMaterialVarFlag(MATERIAL_VAR_IGNOREZ, false);

                m_modelrender()->ForcedMaterialOverride(double_material);
                original_fn(m_modelrender(), ctx, state, info, bone_to_world);
                m_modelrender()->ForcedMaterialOverride(nullptr);
            }

            called_original = true;
        }

        if (!called_original)
            return original_fn(m_modelrender(), ctx, state, info, bone_to_world);
    }
 
axcord.ws
Забаненный
Статус
Оффлайн
Регистрация
8 Апр 2021
Сообщения
178
Реакции[?]
30
Поинты[?]
1K
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
не работает
 
09-29-2022 Thu 18:48:59
Эксперт
Статус
Оффлайн
Регистрация
28 Ноя 2019
Сообщения
1,225
Реакции[?]
413
Поинты[?]
110K
..................................................
Участник
Статус
Оффлайн
Регистрация
13 Авг 2020
Сообщения
990
Реакции[?]
249
Поинты[?]
20K
Спасибо, я вчера весь день пытался понять, как они работают
 
Keep Ev0lving, Stay Fatal
Эксперт
Статус
Оффлайн
Регистрация
6 Фев 2018
Сообщения
1,550
Реакции[?]
586
Поинты[?]
102K
Could you tell me about everything of
C++:
auto weapon_on_back = strstr(name, "_dropped.mdl") && strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto weapon_enemy_hands = strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto defuse_kit = strstr(name, "defuser") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
Or add screenshots with every type of chams (I mean, for what are they).

^ Chams weapon_on_back (Ofc, they doesn`t work while weapon in hands).
Upd:
It made my cheat superior:

Really good work. Should I leave here code for weave.su?
 
Последнее редактирование:
ЧВК EB_LAN
Эксперт
Статус
Онлайн
Регистрация
26 Янв 2021
Сообщения
1,567
Реакции[?]
522
Поинты[?]
185K
Could you tell me about everything of
C++:
auto weapon_on_back = strstr(name, "_dropped.mdl") && strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto weapon_enemy_hands = strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto defuse_kit = strstr(name, "defuser") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
Or add screenshots with every type of chams (I mean, for what are they).

^ Chams weapon_on_back (Ofc, they doesn`t work while weapon in hands).
Upd:
It made my cheat superior:

Really good work. Should I leave here code for weave.su?

Пожалуйста, зарегистрируйтесь или авторизуйтесь, чтобы увидеть содержимое.

 
..................................................
Участник
Статус
Оффлайн
Регистрация
13 Авг 2020
Сообщения
990
Реакции[?]
249
Поинты[?]
20K
Извиняюсь за апп темы и тупой вопрос, а где брать эти названия, типо ("arms", "defuser" )
 
Начинающий
Статус
Оффлайн
Регистрация
22 Июл 2022
Сообщения
26
Реакции[?]
1
Поинты[?]
1K
Could you tell me about everything of
C++:
auto weapon_on_back = strstr(name, "_dropped.mdl") && strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto weapon_enemy_hands = strstr(name, "models/weapons/w") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
auto defuse_kit = strstr(name, "defuser") && !strstr(name, "arms") && !strstr(name, "ied_dropped") && g_cfg.esp.attachment_chams;
Or add screenshots with every type of chams (I mean, for what are they).

^ Chams weapon_on_back (Ofc, they doesn`t work while weapon in hands).
Upd:
It made my cheat superior:

Really good work. Should I leave here code for weave.su?
it doesn't look bad
 
Пользователь
Статус
Оффлайн
Регистрация
3 Май 2021
Сообщения
260
Реакции[?]
48
Поинты[?]
40K
Сверху Снизу