help please...
#1

hi, i have a function to get the player's highest money, but how to get,after that, the 2nd player with the highest money? and not the first one again. Thanks.
Reply
#2

You want to find the player with the most wealth?
Reply
#3

most money and the player with the most money after that.
Reply
#4

online?
pawn Код:
new topid,secondid,topcash,secondcash;
for(new i=0;i<MAX_PLAYERS;i++)
{
    if(GetPlayerMoney(i) > topcash)
    {
        topcash = GetPlayerMoney(i);
        topid = i;
    }
    if(GetPlayerMoney(i) > secondcash && i != topid)
    {
        secondcash = GetPlayerMoney(i);
        secondid = i;
    }
}
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)