Winner Condition

Can’t u just compare the integer value of the kills?
If Player1 kills > Player2 kills do …

hello guys, would you like to know how do i make a winner based on who made the most kills? I have the player’s nick name and death number already programmed, even if they appear on my hud. I would like to know how do I return this player that did more kill so I can create the winner widget?
technically it would be to do a get by player name and number of kills and return which of the people playing has won. in c++

how can i do this with for()?

Create array with all players and loop thought them, use simple max algoryth ergo.

int32 MaxKIlls;
APlayer* PlayerWithMaxKIlls;
for(APlayer& Player : Players)
{
    if(Player.Kills > MaxKIlls)
    {
        MaxKIlls = Player.Kills;
        PlayerWithMaxKIlls = Player;
    }
}

This should return player with highest number of kills

thank you very much, as it is a multiplayer pvp shooting game in LAN mode, how can I call these players? how do i get these logged in players?