Raised This Month: $ Target: $400
 0% 

[L4D2] Player color in Custom Player Stats


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
mcgill
Junior Member
Join Date: Dec 2015
Location: Spain
Old 12-11-2015 , 11:07   [L4D2] Player color in Custom Player Stats
Reply With Quote #1

hello

As the title says I would like coloring players in [L4D & L4D2] Custom Player Stats v1.4B121
like
[L4D2] tystats (Co-op)
if I know that it would be easiest to use the latter, but I've been using custom stats players a long time and would be a shame to start again. I have little idea of programming, but I can not or even can be done ... this snippet adapt to custom player stats.
PHP Code:
public bool TyColorC(int client)
{
    if (
GetClientTeam(client) == 2)
    {
        if (
IsPlayerAlive(client))
        {
            
ig_autoBalance += 2;

            if (
ig_pointsC[client] > 230000)
            {
                
ig_autoBalance += 4;
                
SetEntityRenderColor(client000252);
                return 
true;
            }

            if (
ig_pointsC[client] > 180000)
            {
                
ig_autoBalance += 3;
                
SetEntityRenderColor(client25551204255);
                return 
true;
            }

            if (
ig_pointsC[client] > 120000)
            {
                
ig_autoBalance += 3;
                
SetEntityRenderColor(client1647925255);
                return 
true;
            }

            if (
ig_pointsC[client] > 70000)
            {
                
ig_autoBalance += 2;
                
SetEntityRenderColor(client015351255);
                return 
true;
            }

            if (
ig_pointsC[client] > 30000)
            {
                
ig_autoBalance += 2;
                
SetEntityRenderColor(client051255255);
                return 
true;
            }

            if (
ig_pointsC[client] > 10000)
            {
                
ig_autoBalance += 2;
                
SetEntityRenderColor(client0204255255);
                return 
true;
            }

            if (
ig_pointsC[client] > 0)
            {
                
ig_autoBalance += 1;
                return 
true;
            }
        }
    }
    return 
false;

Part obviously need only color not ig_autoBalance

Someone would be so kind as to tell me if possible and get help?
Thanks
Attached Files
File Type: sp Get Plugin or Get Source (l4d_stats.sp - 317 views - 346.9 KB)
File Type: sp Get Plugin or Get Source (l4d2_tystats_lite_4.3.sp - 330 views - 18.7 KB)
mcgill is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:27.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode