CSX Easy Stats modify

Сообщения
125
Реакции
50
So,i want to modify the code to show /me only when dead based on sayme plugin, is this code ok with this modification or what is the right way?

Код:
#define NOT_ALIVE

GetStats(id, GetStatsFunctions:type)
{
    if(!is_user_connected(id)) continue;
#if defined NOT_ALIVE
    if(is_user_alive(id))
    {
        client_print_color(id, print_team_default, "^1[^3Say-Me^1] You have to be ^3dead ^1to use this!");
        return PLUGIN_HANDLED;
    }   
#endif   
    switch(type)
    {
        case StatsMe:
        {
            new st[ARRSIZE_STATS], bh[ARRSIZE_BODY];
            if(get_user_rstats(id, st, bh) && st[DAMAGE])
            {
                new szFormat[190], len = formatex(szFormat, charsmax(szFormat), "^1[^4Say-Me^1] ^4You made ^3%d ^4dmg >> ", st[DAMAGE]);
                
                for(new i; i < sizeof g_arrBodyMeParts; ++i)
                {
                    if(bh[i])
                    {
                        len += formatex(szFormat[len], charsmax(szFormat) - len, "^3%s^1: ^4%d^1, ", g_arrBodyMeParts[i], bh[i]);
                    }
                }
                
                szFormat[strlen(szFormat) - 2] = EOS;
                client_print_color(id, print_team_default, szFormat);
                
            }
            else    client_print_color(id, print_team_default, "^1[^4Say-Me^1] ^4You ^3didin't hit ^4anyone!");
            ...
thanks
 
Сообщения
2,491
Реакции
2,794
Помог
61 раз(а)
tarsisd2 your message is about modification existing plugin, and doesn't apply to discussion of this resource. If you need help create your own topic with your own problem in future. And if someone else will need this functionality he can find it in one seperate topic without reading a lot of pages. If you decide to ignore forum rules you will get warning.
 
Сообщения
125
Реакции
50
tarsisd2 your message is about modification existing plugin, and doesn't apply to discussion of this resource. If you need help create your own topic with your own problem in future. And if someone else will need this functionality he can find it in one seperate topic without reading a lot of pages. If you decide to ignore forum rules you will get warning.
don't worry, i will not break rules, i just found an easier solution to my problem, that's why i didn't open a new topic, and all i did on my reply was suggest to the developer to add this feature on the plugin so it's more complete if he wants to, don't know why you mention i will get a warning, but thanks for your help!
 

Пользователи, просматривающие эту тему

Сейчас на форуме нет ни одного пользователя.
Сверху Снизу