Raised This Month: $32 Target: $400
 8% 

Solved How to print all with highest int value at round end separately


Post New Thread Reply   
 
Thread Tools Display Modes
alasfourom
Senior Member
Join Date: Feb 2022
Location: Saudi Arabia
Old 08-11-2022 , 08:32   Re: How to print all players/highest player kills at the end of the round?
Reply With Quote #11

Quote:
Originally Posted by Grey83 View Post
PHP Code:
PrintToChatAll("MVP SI Kills: %N (%d)"clientSI_KillCount_MVP); 
==>
PHP Code:
if(SI_KillCount_MVP 0PrintToChatAll("MVP SI Kills: %N (%d)"clientSI_KillCount_MVP);
else 
PrintToChatAll("MVP SI Kills: %N (None)"client); 
Noice, got it now

Thanks as always Grey83,
__________________
alasfourom is offline
alasfourom
Senior Member
Join Date: Feb 2022
Location: Saudi Arabia
Old 08-11-2022 , 08:57   Re: How to print all players/highest player kills at the end of the round?
Reply With Quote #12

Quote:
Originally Posted by Bacardi View Post
...tips
Code:
public void Event_RoundStart(Event event, const char[] name, bool dontBroadcast)
{
    g_bRoundEnd = false;
    
    for (int i = 1; i <= MaxClients; i++)
    {
        if (IsClientInGame(i))
        {
            SI_KillCount     [i] = 0;
            Boss_KillCount    [i] = 0;
        }
    }
}
Why not reset whole array, either client is in game or not.
Thanks I changed it now,


Quote:
Originally Posted by Bacardi View Post
I don't remember L4D teams, but now you exlude clients from that team only. What about spectators ?
Should it be GetClientTeam(client) != 2, if any another team than index 2

Thanks for the tips, yeah I should have changed that cause it showed even some spec kills when they go afk, excellent Bacardi

Quote:
Originally Posted by Bacardi View Post
This look nonsense, what happened here ?
Me neither , I'm not familiar with it, what my end result which is working at least < I'm sure its not the best way > is like this, when round end it will print in this way:

MVP SI Kills: Mike (12)
MVP Boss Kills: Sara (2)


only the one with highest value and ignoring the rest of players with lower value
__________________

Last edited by alasfourom; 08-11-2022 at 09:01.
alasfourom is offline
Reply


Thread Tools
Display Modes

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 19:03.


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